Skip to content

Protect deployment database connections - #2057

Merged
RhysSullivan merged 2 commits into
mainfrom
fix/database-connection-safeguards
Sep 18, 2026
Merged

RhysSullivan merged 2 commits into
mainfrom
fix/database-connection-safeguards

Conversation

@RhysSullivan

@RhysSullivan RhysSullivan commented Sep 18, 2026

Copy link
Copy Markdown
Collaborator

Deployment scripts currently stop as soon as PostgreSQL refuses a connection with SQLSTATE 53300. Add a bounded connection preflight to migrations and the membership-readiness gate. Retry admission only; migration bodies and readiness mutations still run once. Reject PlanetScale pooler URLs for these session-sensitive scripts.

Add a five-minute Actions capacity check that fails below ten ordinary free connections, and document the hard PgBouncer budget, direct deployment route, and safe cutover procedure. Scheduled checks use existing Actions failure notifications and become active after merge.

Validation: focused connection tests, real PostgreSQL 18 recovery followed by all schema migrations, and an isolated PgBouncer test with 32 clients capped at 12 backends while direct migration access remained available. Prepared statements passed across backend reassignment. Format, lint, typecheck, and the full Test job passed in CI. Workflow validation passed locally. All CI checks passed on the updated head. The existing cap-eviction E2E scenario timed out on earlier attempts with Durable Object concurrency resets while its test database remained healthy; it passed on a fresh CI runner (3.7 seconds), standalone locally, and in the full local shard (39 tests). The timeout cause remains unresolved. No E2E assertions or runtime behavior were changed.

@github-actions

github-actions Bot commented Sep 18, 2026

Copy link
Copy Markdown
Contributor

Cloudflare preview

Torn down — the PR is closed.

@pkg-pr-new

pkg-pr-new Bot commented Sep 18, 2026

Copy link
Copy Markdown

Open in StackBlitz

@executor-js/cli

npm i https://pkg.pr.new/@executor-js/cli@2057

@executor-js/config

npm i https://pkg.pr.new/@executor-js/config@2057

@executor-js/execution

npm i https://pkg.pr.new/@executor-js/execution@2057

@executor-js/sdk

npm i https://pkg.pr.new/@executor-js/sdk@2057

@executor-js/codemode-core

npm i https://pkg.pr.new/@executor-js/codemode-core@2057

@executor-js/runtime-quickjs

npm i https://pkg.pr.new/@executor-js/runtime-quickjs@2057

@executor-js/plugin-file-secrets

npm i https://pkg.pr.new/@executor-js/plugin-file-secrets@2057

@executor-js/plugin-graphql

npm i https://pkg.pr.new/@executor-js/plugin-graphql@2057

@executor-js/plugin-keychain

npm i https://pkg.pr.new/@executor-js/plugin-keychain@2057

@executor-js/plugin-mcp

npm i https://pkg.pr.new/@executor-js/plugin-mcp@2057

@executor-js/plugin-onepassword

npm i https://pkg.pr.new/@executor-js/plugin-onepassword@2057

@executor-js/plugin-openapi

npm i https://pkg.pr.new/@executor-js/plugin-openapi@2057

executor

npm i https://pkg.pr.new/executor@2057

commit: 66a82a1

@RhysSullivan
RhysSullivan marked this pull request as ready for review September 18, 2026 18:52
@cloudflare-workers-and-pages

Copy link
Copy Markdown

Deploying with  Cloudflare Workers  Cloudflare Workers

The latest updates on your project. Learn more about integrating Git with Workers.

Status Name Latest Commit Preview URL Updated (UTC)
✅ Deployment successful!
View logs
executor-marketing 66a82a1 Commit Preview URL

Branch Preview URL
Sep 18 2026, 06:59 PM

@RhysSullivan
RhysSullivan merged commit 25a490d into main Sep 18, 2026
79 of 80 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant