Kea
1.9.9-git
|
PostgreSQL Lease Context. More...
#include <pgsql_lease_mgr.h>
Public Member Functions | |
PgSqlLeaseContext (const db::DatabaseConnection::ParameterMap ¶meters, db::IOServiceAccessorPtr io_service_accessor, db::DbCallback db_reconnect_callback) | |
Constructor. More... | |
Public Attributes | |
db::PgSqlConnection | conn_ |
PostgreSQL connection. More... | |
boost::scoped_ptr< PgSqlLease4Exchange > | exchange4_ |
The exchange objects are used for transfer of data to/from the database. More... | |
boost::scoped_ptr< PgSqlLease6Exchange > | exchange6_ |
Exchange object. More... | |
PostgreSQL Lease Context.
This class stores the thread context for the manager pool. The class is needed by all get/update/delete functions which must use one or more exchanges to perform database operations. Each context provides a set of such exchanges for each thread. The context instances are lazy initialized by the requesting thread by using the manager's createContext function and are destroyed when the manager's pool instance is destroyed.
Definition at line 40 of file pgsql_lease_mgr.h.
isc::dhcp::PgSqlLeaseContext::PgSqlLeaseContext | ( | const db::DatabaseConnection::ParameterMap & | parameters, |
db::IOServiceAccessorPtr | io_service_accessor, | ||
db::DbCallback | db_reconnect_callback | ||
) |
Constructor.
parameters | See PgSqlLeaseMgr constructor. |
io_service_accessor | The IOService accessor function. |
db_reconnect_callback | The connection recovery callback. |
Definition at line 1173 of file pgsql_lease_mgr.cc.
db::PgSqlConnection isc::dhcp::PgSqlLeaseContext::conn_ |
PostgreSQL connection.
Definition at line 60 of file pgsql_lease_mgr.h.
boost::scoped_ptr<PgSqlLease4Exchange> isc::dhcp::PgSqlLeaseContext::exchange4_ |
The exchange objects are used for transfer of data to/from the database.
They are pointed-to objects as the contents may change in "const" calls, while the rest of this object does not. (At alternative would be to declare them as "mutable".) Exchange object
Definition at line 56 of file pgsql_lease_mgr.h.
boost::scoped_ptr<PgSqlLease6Exchange> isc::dhcp::PgSqlLeaseContext::exchange6_ |
Exchange object.
Definition at line 57 of file pgsql_lease_mgr.h.