fix(Core/DatabseWorkerPool): implement DatabaseIncompatibleVersion to better support MariaDB (#18201)

* fix(Core): Rework Database Version Check for MariaDB support

* incorporate "smarter" version comparison

* rename function to be more accurate

* Factor magic numbers into defines. Revise comments

* clean up triple newline

* Doxygenify the docs

* remove blankspace

---------

Co-authored-by: Kitzunu <24550914+Kitzunu@users.noreply.github.com>
This commit is contained in:
Mike Delago
2024-01-21 08:48:57 -05:00
committed by GitHub
parent e447351b0f
commit d0eae390b6
4 changed files with 96 additions and 11 deletions

View File

@@ -24,6 +24,34 @@
#include <array>
#include <vector>
/** @file DatabaseWorkerPool.h */
/**
* @def MIN_MYSQL_CLIENT_VERSION
* The minimum MariaDB Client Version
* MARIADB_VERSION_ID is defined if using libmariadbclient instead of libmysqlclient
*/
#if MARIADB_VERSION_ID >= 100600
#define MIN_MYSQL_CLIENT_VERSION 30203u
#else
/**
* @def MIN_MYSQL_CLIENT_VERSION
* The minimum MySQL Client Version
*/
#define MIN_MYSQL_CLIENT_VERSION 50700u
#endif
/**
* @def MIN_MYSQL_SERVER_VERSION
* The minimum MySQL Server Version
*/
#define MIN_MYSQL_SERVER_VERSION "5.7.0"
/**
* @def MIN_MARIADB_SERVER_VERSION
* The minimum MariaDB Server Version
*/
#define MIN_MARIADB_SERVER_VERSION "10.5.0"
template <typename T>
class ProducerConsumerQueue;