cp_db_connection_pool_get_connection(3) - Linux man page

Name

cp_db_connection_pool_get_connection, cp_db_connection_pool_release_connection - retrieve / return a connection from a connection pool

Synopsis

#include <cprops/db.h>

cp_db_connection *

cp_db_connection_pool_get_connection(cp_db_connection_pool *pool);
void
cp_db_connection_pool_release_connection(cp_db_connection_pool *pool,

cp_db_connection *conn);

Description

cp_db_connection_pool_get_connection retrieves a connection from a connection pool. If the connection pool has no more connections available cp_db_connection_pool_get_connection either returns NULL, or blocks until a connection becomes available if the pool was set to block.

cp_db_connection_pool_release_connection returns a connection to the pool for reuse. Connections retrieved with cp_db_connection_pool_get_connection should not be closed explicitly.

Return Value

cp_db_connection_pool_create returns a cp_db_connection_pool structure representing the newly created connection pool on success or NULL on failure.

See Also

cp_db_connection_pool_set_blocking(3)

Referenced By

cp_db_connection_pool_destroy(3), cp_dbms(3)