# HG changeset patch # User Sebastien Jodogne # Date 1547139867 -3600 # Node ID d16e94157efed30b814658268159990cf47e24f7 # Parent 1012fe77241c6a5c991779ce22150aef49437f17# Parent b96446b8718ba9998abd52b283a85a5506fc0143 integration mainline->db-changes diff -r 1012fe77241c -r d16e94157efe MySQL/NEWS --- a/MySQL/NEWS Thu Jan 10 18:04:12 2019 +0100 +++ b/MySQL/NEWS Thu Jan 10 18:04:27 2019 +0100 @@ -2,6 +2,7 @@ =============================== * Characters "$" and "_" are allowed in MySQL database identifiers +* Fix serialization of jobs if many of them Release 1.1 (2018-07-18) diff -r 1012fe77241c -r d16e94157efe MySQL/Plugins/MySQLIndex.cpp --- a/MySQL/Plugins/MySQLIndex.cpp Thu Jan 10 18:04:12 2019 +0100 +++ b/MySQL/Plugins/MySQLIndex.cpp Thu Jan 10 18:04:27 2019 +0100 @@ -116,7 +116,19 @@ SetGlobalIntegerProperty(*db, t, Orthanc::GlobalProperty_DatabasePatchLevel, revision); } - if (revision != 1) + if (revision == 1) + { + // The serialization of jobs as a global property can lead to + // very long values => switch to the LONGTEXT type that can + // store up to 4GB: + // https://stackoverflow.com/a/13932834/881731 + db->Execute("ALTER TABLE GlobalProperties MODIFY value LONGTEXT", false); + + revision = 2; + SetGlobalIntegerProperty(*db, t, Orthanc::GlobalProperty_DatabasePatchLevel, revision); + } + + if (revision != 2) { LOG(ERROR) << "MySQL plugin is incompatible with database schema revision: " << revision; throw Orthanc::OrthancException(Orthanc::ErrorCode_Database); diff -r 1012fe77241c -r d16e94157efe Resources/CMake/DatabasesFrameworkConfiguration.cmake --- a/Resources/CMake/DatabasesFrameworkConfiguration.cmake Thu Jan 10 18:04:12 2019 +0100 +++ b/Resources/CMake/DatabasesFrameworkConfiguration.cmake Thu Jan 10 18:04:27 2019 +0100 @@ -30,6 +30,10 @@ set(ENABLE_CRYPTO_OPTIONS ON) set(ENABLE_SSL ON) set(ENABLE_ZLIB ON) + + if ("${CMAKE_SYSTEM_NAME}" STREQUAL "Windows") + set(ENABLE_OPENSSL_ENGINES ON) + endif() endif() if (ENABLE_MYSQL_BACKEND) diff -r 1012fe77241c -r d16e94157efe Resources/CMake/PostgreSQLConfiguration.cmake --- a/Resources/CMake/PostgreSQLConfiguration.cmake Thu Jan 10 18:04:12 2019 +0100 +++ b/Resources/CMake/PostgreSQLConfiguration.cmake Thu Jan 10 18:04:27 2019 +0100 @@ -123,6 +123,13 @@ ) endif() + if (ENABLE_SSL) + add_definitions( + -DHAVE_LIBSSL=1 + -DUSE_OPENSSL=1 + ) + endif() + elseif(CROSS_COMPILING) message(FATAL_ERROR "Cannot auto-generate the configuration file cross-compiling") @@ -229,7 +236,6 @@ check_include_files("sys/socket.h;netinet/tcp.h" HAVE_NETINET_TCP_H) endif() - if (ENABLE_SSL) set(HAVE_LIBSSL 1) set(HAVE_SSL_GET_CURRENT_COMPRESSION 1)