CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
ConnectionPool.h
Go to the documentation of this file.
1 #ifndef ConditionDatabase_ConnectionPool_h
2 #define ConditionDatabase_ConnectionPool_h
3 
5 //
6 #include <string>
7 #include <memory>
8 //
9 #include "CoralBase/MessageStream.h"
10 
11 namespace edm {
12  class ParameterSet;
13 }
14 
15 namespace coral {
16  class IConnectionServiceConfiguration;
17  class ISessionProxy;
18  class IMsgReporter;
19 } // namespace coral
20 
21 namespace cond {
22  class CoralServiceManager;
23 }
24 
25 namespace cond {
26 
27  namespace persistency {
28  //
29  class CoralMsgReporter;
30  class Logger;
31 
33 
34  // a wrapper for the coral connection service.
36  public:
39 
40  void setMessageVerbosity(coral::MsgLevel level);
42  void setAuthenticationPath(const std::string& p);
43  void setAuthenticationSystem(int authSysCode);
45  void setLogging(bool flag);
46  void setConnectionTimeout(int seconds);
47  bool isLoggingEnabled() const;
48  void setParameters(const edm::ParameterSet& connectionPset);
49  void configure();
50  Session createSession(const std::string& connectionString, bool writeCapable = false);
51  Session createReadOnlySession(const std::string& connectionString, const std::string& transactionId);
52  std::shared_ptr<coral::ISessionProxy> createCoralSession(const std::string& connectionString,
53  bool writeCapable = false);
54 
55  private:
56  std::shared_ptr<coral::ISessionProxy> createCoralSession(const std::string& connectionString,
57  const std::string& transactionId,
58  bool writeCapable = false);
59  Session createSession(const std::string& connectionString,
60  const std::string& transactionId,
61  bool writeCapable = false);
62  void configure(coral::IConnectionServiceConfiguration& coralConfig);
63 
64  private:
66  int m_authSys = 0;
68  coral::MsgLevel m_messageLevel = coral::Error;
71  bool m_loggingEnabled = false;
72  //The frontier security option is turned on for all sessions
73  //usig this wrapper of the CORAL connection setup for configuring the server access
75  // this one has to be moved!
77  };
78  } // namespace persistency
79 } // namespace cond
80 
81 #endif
edm::ErrorSummaryEntry Error
void setLogDestination(Logger &logger)
tuple logger
Definition: conddblib.py:25
double seconds()
void setParameters(const edm::ParameterSet &connectionPset)
void setAuthenticationSystem(int authSysCode)
Session createSession(const std::string &connectionString, bool writeCapable=false)
void setMessageVerbosity(coral::MsgLevel level)
Session createReadOnlySession(const std::string &connectionString, const std::string &transactionId)
tuple level
Definition: testEve_cfg.py:47
cond::CoralServiceManager * m_pluginManager
The Signals That Services Can Subscribe To This is based on ActivityRegistry and is current per Services can connect to the signals distributed by the ActivityRegistry in order to monitor the activity of the application Each possible callback has some defined signature
Definition: Activities.doc:4
void setAuthenticationPath(const std::string &p)
std::shared_ptr< coral::ISessionProxy > createCoralSession(const std::string &connectionString, bool writeCapable=false)
void setFrontierSecurity(const std::string &signature)