Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions docker/docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,12 @@ services:
postgres:
image: postgres:15.0-alpine
container_name: mpcautofill_postgres
# client_connection_check_interval (Postgres 14+): probes the client socket
# periodically DURING query execution and aborts the query if the client is
# gone, rather than computing to completion for a dead client (issue #462).
# Deliberately NOT statement_timeout - BULK-mode eligibility scans legitimately
# run for minutes-hours with a live client and must not be killed.
command: postgres -c client_connection_check_interval=30000
ports:
- "127.0.0.1:5432:5432"
environment:
Expand Down
5 changes: 5 additions & 0 deletions docs/infrastructure.md
Original file line number Diff line number Diff line change
Expand Up @@ -107,6 +107,11 @@ this fixed and its follow-on hardening. Fixed by `eaece1fd` (#18,
recreates the `django` container), also restart `nginx`** — see
[[troubleshooting.md]] ("nginx 502s everything after a django container
restart") for the mechanism and exact fix.
- **`client_connection_check_interval=30000`** (postgres `command:`, issue
#462) makes a backend abort its query if the client socket died mid-query
instead of computing to completion for nobody. Rollout requires one
deliberate `postgres` container recreate (seconds of DB downtime) — django
and the worker reconnect on their own, no restart needed for either.

### Boot-time recovery

Expand Down
Loading