mirror of
https://gitee.com/nocobase/nocobase.git
synced 2025-07-01 18:52:20 +08:00
Update packages/core/database/src/helpers.ts
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
This commit is contained in:
parent
3be05a537b
commit
463c8bc8bc
@ -94,6 +94,7 @@ export async function parseDatabaseOptionsFromEnv(): Promise<IDatabaseOptions> {
|
||||
acquire: process.env.DB_POOL_ACQUIRE ? Number.parseInt(process.env.DB_POOL_ACQUIRE, 10) : 60_000,
|
||||
evict: process.env.DB_POOL_EVICT ? Number.parseInt(process.env.DB_POOL_EVICT, 10) : 1000,
|
||||
maxUses: process.env.DB_POOL_MAX_USES
|
||||
// If DB_POOL_MAX_USES is '0', it is treated as falsy and defaults to Number.POSITIVE_INFINITY.
|
||||
? Number.parseInt(process.env.DB_POOL_MAX_USES, 10) || Number.POSITIVE_INFINITY
|
||||
: Number.POSITIVE_INFINITY,
|
||||
},
|
||||
|
Loading…
x
Reference in New Issue
Block a user