Skip to content

pool-guard.mjs

  • Event: PreToolUse Edit/Write
  • Type: notice: informs or reminds, does not block

WARNS (does not block; once per file and session) about what exhausts the database connection pool in Node/TS and Python: new PrismaClient() without a global singleton (in serverless it opens one connection per invocation), and creating a pool/client/engine inside per-request code (routes, controllers, endpoints). PHP-FPM is out of scope. Recipe: code-quality/references/database-design.md (§Conexiones y pool).

See the code of pool-guard.mjs on GitHub