comparison Framework/PostgreSQL/PostgreSQLParameters.h @ 429:dbf811b1bb43 pg-transactions

new configuration 'EnableVerboseLogs' to log SQL statements being executed
author Alain Mazy <am@osimis.io>
date Thu, 30 Nov 2023 14:47:23 +0100
parents 15bfd9a76f8d
children 8b7c1c423367
comparison
equal deleted inserted replaced
428:4d0bacbd0fba 429:dbf811b1bb43
43 bool lock_; 43 bool lock_;
44 unsigned int maxConnectionRetries_; 44 unsigned int maxConnectionRetries_;
45 unsigned int connectionRetryInterval_; 45 unsigned int connectionRetryInterval_;
46 std::string readWriteTransactionStatement_; 46 std::string readWriteTransactionStatement_;
47 std::string readOnlyTransactionStatement_; 47 std::string readOnlyTransactionStatement_;
48 bool isVerboseEnabled_;
48 49
49 void Reset(); 50 void Reset();
50 51
51 public: 52 public:
52 PostgreSQLParameters(); 53 PostgreSQLParameters();
145 const std::string& GetReadOnlyTransactionStatement() const 146 const std::string& GetReadOnlyTransactionStatement() const
146 { 147 {
147 return readOnlyTransactionStatement_; 148 return readOnlyTransactionStatement_;
148 } 149 }
149 150
151 void SetVerboseEnabled(bool enabled)
152 {
153 isVerboseEnabled_ = enabled;
154 }
155
156 bool IsVerboseEnabled() const
157 {
158 return isVerboseEnabled_;
159 }
160
161
150 void Format(std::string& target) const; 162 void Format(std::string& target) const;
151 }; 163 };
152 } 164 }