Mercurial > hg > orthanc-databases
comparison MySQL/Plugins/IndexPlugin.cpp @ 42:4c3f767ead03 OrthancMySQL-1.0
set version
author | Sebastien Jodogne <s.jodogne@gmail.com> |
---|---|
date | Tue, 17 Jul 2018 08:38:11 +0200 |
parents | 5600949bfb12 |
children | eedd082355f9 |
comparison
equal
deleted
inserted
replaced
41:f729a4b6f37a | 42:4c3f767ead03 |
---|---|
23 #include "../../Framework/MySQL/MySQLDatabase.h" | 23 #include "../../Framework/MySQL/MySQLDatabase.h" |
24 #include "../../Framework/Plugins/PluginInitialization.h" | 24 #include "../../Framework/Plugins/PluginInitialization.h" |
25 | 25 |
26 #include <Core/HttpClient.h> | 26 #include <Core/HttpClient.h> |
27 #include <Core/Logging.h> | 27 #include <Core/Logging.h> |
28 #include <Core/Toolbox.h> | |
28 | 29 |
29 static std::auto_ptr<OrthancDatabases::MySQLIndex> backend_; | 30 static std::auto_ptr<OrthancDatabases::MySQLIndex> backend_; |
30 | 31 |
31 | 32 |
32 extern "C" | 33 extern "C" |
36 if (!OrthancDatabases::InitializePlugin(context, "MySQL", true)) | 37 if (!OrthancDatabases::InitializePlugin(context, "MySQL", true)) |
37 { | 38 { |
38 return -1; | 39 return -1; |
39 } | 40 } |
40 | 41 |
42 Orthanc::Toolbox::InitializeOpenSsl(); | |
41 Orthanc::HttpClient::GlobalInitialize(); | 43 Orthanc::HttpClient::GlobalInitialize(); |
42 | 44 |
43 OrthancPlugins::OrthancConfiguration configuration(context); | 45 OrthancPlugins::OrthancConfiguration configuration(context); |
44 | 46 |
45 if (!configuration.IsSection("MySQL")) | 47 if (!configuration.IsSection("MySQL")) |
90 LOG(WARNING) << "MySQL index is finalizing"; | 92 LOG(WARNING) << "MySQL index is finalizing"; |
91 | 93 |
92 backend_.reset(NULL); | 94 backend_.reset(NULL); |
93 OrthancDatabases::MySQLDatabase::GlobalFinalization(); | 95 OrthancDatabases::MySQLDatabase::GlobalFinalization(); |
94 Orthanc::HttpClient::GlobalFinalize(); | 96 Orthanc::HttpClient::GlobalFinalize(); |
97 Orthanc::Toolbox::FinalizeOpenSsl(); | |
95 } | 98 } |
96 | 99 |
97 | 100 |
98 ORTHANC_PLUGINS_API const char* OrthancPluginGetName() | 101 ORTHANC_PLUGINS_API const char* OrthancPluginGetName() |
99 { | 102 { |