@hotmeshio/hotmesh
Version:
Serverless Workflow
21 lines (20 loc) • 1.15 kB
TypeScript
import { AbstractConnection } from '..';
import { PostgresClientOptions, PostgresClientType, PostgresClassType, PostgresPoolClientType } from '../../../types/postgres';
declare class PostgresConnection extends AbstractConnection<PostgresClassType, PostgresClientOptions> {
defaultOptions: PostgresClientOptions;
protected static poolClientInstances: Set<PostgresPoolClientType>;
protected static connectionInstances: Set<PostgresClientType>;
poolClientInstance: PostgresPoolClientType;
createConnection(clientConstructor: any, options: PostgresClientOptions, config?: {
connect?: boolean;
provider?: string;
}): Promise<PostgresClientType>;
getClient(): PostgresClientType;
static disconnectAll(): Promise<void>;
static disconnectPoolClients(): Promise<void>;
static disconnectConnections(): Promise<void>;
closeConnection(connection: PostgresClientType): Promise<void>;
static isPoolClient(client: any): client is PostgresPoolClientType;
static getTransactionClient(transactionClient: any): Promise<['client' | 'poolclient', PostgresClientType]>;
}
export { PostgresConnection };