From fe9e661b2577890bbe494ae0086193cc4b620b5a Mon Sep 17 00:00:00 2001 From: Waleed Latif Date: Wed, 18 Mar 2026 02:06:16 -0700 Subject: [PATCH] fix(db): reduce connection pool sizes to prevent exhaustion --- apps/sim/socket/database/operations.ts | 2 +- packages/db/index.ts | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/apps/sim/socket/database/operations.ts b/apps/sim/socket/database/operations.ts index aad62ef8b3d..60cfa177e6b 100644 --- a/apps/sim/socket/database/operations.ts +++ b/apps/sim/socket/database/operations.ts @@ -29,7 +29,7 @@ const socketDb = drizzle( prepare: false, idle_timeout: 10, connect_timeout: 20, - max: 15, + max: 10, onnotice: () => {}, }), { schema } diff --git a/packages/db/index.ts b/packages/db/index.ts index 186b076abaf..0cab65a38e3 100644 --- a/packages/db/index.ts +++ b/packages/db/index.ts @@ -14,7 +14,7 @@ const postgresClient = postgres(connectionString, { prepare: false, idle_timeout: 20, connect_timeout: 30, - max: 30, + max: 10, onnotice: () => {}, })