.env.example and the README still told people to use pgCat on :6432, the exact setup that hangs on every parameterised query. With no prod and one backend instance there is nothing for a pooler to multiplex, and postgres-js already pools in-process, so DATABASE_URL now points at Postgres on :5432 in .env.example, dev-env.sh and drizzle.config.ts. prepare:false is kept in src/db/index.ts on purpose, so adding PgBouncer later (tested working) is a config change rather than a code change. The long measurement narrative in that file's comment is cut to the decision and the pointer to PLAN.md, where the numbers now live.
16 lines
508 B
TypeScript
16 lines
508 B
TypeScript
import { defineConfig } from "drizzle-kit";
|
|
|
|
export default defineConfig({
|
|
schema: "./src/db/schema/index.ts",
|
|
out: "./drizzle",
|
|
dialect: "postgresql",
|
|
dbCredentials: {
|
|
// Matches scripts/dev-env.sh's DEV_DATABASE_URL and .env.example: straight
|
|
// at Postgres. Migrations must never go through a pooler - drizzle-kit
|
|
// cannot pass `prepare: false`.
|
|
url: process.env.DATABASE_URL ?? "postgres://continuum:continuum@localhost:5432/continuum",
|
|
},
|
|
verbose: true,
|
|
strict: true,
|
|
});
|