Database
The database is one Postgres instance holding the task store, the ledger, connector queues, schedules and memory.
Migrations are the numbered files in migrations/, embedded in the binary and applied in order at boot, forward only. A schema change is a new file; never edit an applied one.
With database.maxOpenConnections unset or 0, the daemon asks Postgres for max_connections minus superuser_reserved_connections and fails if that is below 1. Idle connections match the open limit, idle time is 10 minutes and a connection's lifetime 30 minutes. Health reports pool exhaustion (in use, allowed, waiters) when it cannot get a connection.