ConnectionPoolOptions
Defined in: src/core/ConnectionPool.ts:38
Options for createPooledTransferClient.
Properties
Section titled “Properties”| Property | Type | Description | Defined in |
|---|---|---|---|
idleTimeoutMs? | number | How long an idle session may sit unused before it is automatically disconnected. Defaults to 60_000 ms. Set to 0 to disable the timer (idle sessions persist until drainPool() is called). | src/core/ConnectionPool.ts:53 |
keyOf? | (profile: ConnectionProfile) => string | Custom pool key derivation. Receives the resolved ConnectionProfile (after TransferClient validation) and must return a string. Sessions with matching keys are pooled together; never include secrets in the key. The default derives the key from provider, host, port, and username. | src/core/ConnectionPool.ts:63 |
maxIdlePerKey? | number | Maximum number of idle sessions retained per pool key. Active leases are not counted against this limit - the cap only applies to sessions waiting in the pool. When more than maxIdlePerKey sessions become idle simultaneously, the oldest ones are disconnected. Defaults to 4. | src/core/ConnectionPool.ts:47 |