+1
-1
| export { getPgEnvOptions, getPgEnvVars, getSpawnEnvWithPg, toPgEnvVars } from './env'; | ||
| export { defaultPgConfig, PgConfig } from './pg-config'; | ||
| export { defaultPgConfig, PgConfig, PgPoolConfig } from './pg-config'; |
+16
-0
@@ -8,2 +8,18 @@ export interface PgConfig { | ||
| } | ||
| /** | ||
| * Optional pool sizing configuration. | ||
| * | ||
| * Passed through to node-postgres `pg.Pool` options. | ||
| * When omitted, pg-cache falls back to its own env-var defaults. | ||
| */ | ||
| export interface PgPoolConfig { | ||
| /** Maximum number of clients in the pool (env: PG_POOL_MAX, default: 5) */ | ||
| max?: number; | ||
| /** Close idle clients after this many ms (env: PG_POOL_IDLE_TIMEOUT_MS, default: 30000) */ | ||
| idleTimeoutMillis?: number; | ||
| /** Reject pool.connect() after this many ms (env: PG_POOL_CONNECTION_TIMEOUT_MS, default: 5000) */ | ||
| connectionTimeoutMillis?: number; | ||
| /** Allow the Node process to exit while idle clients remain (default: false) */ | ||
| allowExitOnIdle?: boolean; | ||
| } | ||
| export declare const defaultPgConfig: PgConfig; |
+1
-1
| export { getPgEnvOptions, getPgEnvVars, getSpawnEnvWithPg, toPgEnvVars } from './env'; | ||
| export { defaultPgConfig, PgConfig } from './pg-config'; | ||
| export { defaultPgConfig, PgConfig, PgPoolConfig } from './pg-config'; |
+2
-2
| { | ||
| "name": "pg-env", | ||
| "version": "1.14.0", | ||
| "version": "1.15.0", | ||
| "author": "Constructive <developers@constructive.io>", | ||
@@ -41,3 +41,3 @@ "description": "PostgreSQL environment configuration utilities", | ||
| }, | ||
| "gitHead": "50dc1d69049c207b46c237eba1e1b1cb7a5f928f" | ||
| "gitHead": "c0d04574f7719d92e67becb58d60791ae978c5f5" | ||
| } |
+16
-0
@@ -8,2 +8,18 @@ export interface PgConfig { | ||
| } | ||
| /** | ||
| * Optional pool sizing configuration. | ||
| * | ||
| * Passed through to node-postgres `pg.Pool` options. | ||
| * When omitted, pg-cache falls back to its own env-var defaults. | ||
| */ | ||
| export interface PgPoolConfig { | ||
| /** Maximum number of clients in the pool (env: PG_POOL_MAX, default: 5) */ | ||
| max?: number; | ||
| /** Close idle clients after this many ms (env: PG_POOL_IDLE_TIMEOUT_MS, default: 30000) */ | ||
| idleTimeoutMillis?: number; | ||
| /** Reject pool.connect() after this many ms (env: PG_POOL_CONNECTION_TIMEOUT_MS, default: 5000) */ | ||
| connectionTimeoutMillis?: number; | ||
| /** Allow the Node process to exit while idle clients remain (default: false) */ | ||
| allowExitOnIdle?: boolean; | ||
| } | ||
| export declare const defaultPgConfig: PgConfig; |
17123
8.93%170
23.19%