Skip to main content

Class: DBConnectionPool

@divine/uri.DBDriver.DBConnectionPool

Constructors

constructor

new DBConnectionPool(_dbURI, params)

Parameters

NameType
_dbURIDatabaseURI
paramsDBParamsSelector

Defined in

uri/src/database-driver.ts:52

Properties

_dbURI

Protected _dbURI: DatabaseURI

Defined in

uri/src/database-driver.ts:52


_params

Protected _params: DBParams

Defined in

uri/src/database-driver.ts:44


defaultBackoff

Static Readonly defaultBackoff: (count: number) => number

Type declaration

▸ (count): number

Parameters
NameType
countnumber
Returns

number

Defined in

uri/src/database-driver.ts:38


defaultKeepalive

Static Readonly defaultKeepalive: 10000

Defined in

uri/src/database-driver.ts:41


defaultMaxConnections

Static Readonly defaultMaxConnections: 10

Defined in

uri/src/database-driver.ts:42


defaultRetries

Static Readonly defaultRetries: 8

Defined in

uri/src/database-driver.ts:37


defaultTTL

Static Readonly defaultTTL: 30000

Defined in

uri/src/database-driver.ts:40


defaultTimeout

Static Readonly defaultTimeout: 60000

Defined in

uri/src/database-driver.ts:39

Methods

_createDBConnection

Protected Abstract _createDBConnection(): DBConnection | Promise<DBConnection>

Returns

DBConnection | Promise<DBConnection>

Defined in

uri/src/database-driver.ts:57


_getAuthorization

Protected _getAuthorization(challenges?): Promise<undefined | Authorization>

Parameters

NameType
challengesWWWAuthenticate[]

Returns

Promise<undefined | Authorization>

Defined in

uri/src/database-driver.ts:100


_getCredentials

Protected _getCredentials(): Promise<undefined | PasswordCredentials>

Returns

Promise<undefined | PasswordCredentials>

Defined in

uri/src/database-driver.ts:107


close

close(): Promise<void>

Returns

Promise<void>

Defined in

uri/src/database-driver.ts:92


session

session<T>(cb): Promise<T>

Type parameters

Name
T

Parameters

NameType
cb(connection: DBConnection) => Promise<T>

Returns

Promise<T>

Defined in

uri/src/database-driver.ts:59