| 12 | export type Connection = object; |
| 13 | |
| 14 | export interface ConnectionManager { |
| 15 | refreshTypeParser(dataTypes: object): void; |
| 16 | /** |
| 17 | * Drain the pool and close it permanently |
| 18 | */ |
| 19 | close(): Promise<void>; |
| 20 | /** |
| 21 | * Initialize connection pool. By default pool autostart is set to false, so no connection will be |
| 22 | * be created unless `pool.acquire` is called. |
| 23 | */ |
| 24 | initPools(): void; |
| 25 | /** |
| 26 | * Get connection from pool. It sets database version if it's not already set. |
| 27 | * Call pool.acquire to get a connection. |
| 28 | */ |
| 29 | getConnection(opts: GetConnectionOptions): Promise<Connection>; |
| 30 | /** |
| 31 | * Release a pooled connection, so it can be utilized by other connection requests |
| 32 | */ |
| 33 | releaseConnection(conn: Connection): void; |
| 34 | |
| 35 | /** |
| 36 | * Destroys a pooled connection and removes it from the pool. |
| 37 | */ |
| 38 | destroyConnection(conn: Connection): Promise<void>; |
| 39 | } |
no outgoing calls
no test coverage detected