Skip to content

feat: add PostgreSQL recovery rehearsal - #18

Open
seonghobae wants to merge 3 commits into
feat/completion-correctionfrom
feat/postgresql-recovery-evidence
Open

feat: add PostgreSQL recovery rehearsal#18
seonghobae wants to merge 3 commits into
feat/completion-correctionfrom
feat/postgresql-recovery-evidence

Conversation

@seonghobae

Copy link
Copy Markdown
Contributor

Summary

  • add a forward audit-correlation index migration
  • add a disposable native PostgreSQL backup/restore rehearsal with measured tenant skew, RLS preservation, and forward-migration assertions
  • update the operational readiness, ADR, PRD, TRD, changelog, README, and gap register

Real local evidence

  • PostgreSQL 18.4
  • 1,000 anonymized audit events across tenants with 900/100 distribution and 9.00 skew ratio
  • dump/restore preserved the tenant distribution, 16 policies, and 16 forced-RLS relations
  • forward 0002_audit_correlation_index.sql applied successfully

Verification

  • shellcheck scripts/postgres_recovery_rehearsal.sh
  • PGHOST=127.0.0.1 PGPORT=5432 PGUSER=$(id -un) scripts/postgres_recovery_rehearsal.sh
  • cargo +1.97.1 fmt --all -- --check
  • cargo +1.97.1 test --workspace --all-targets --locked
  • cargo +1.97.1 clippy --workspace --all-targets --locked -- -D warnings
  • RUSTDOCFLAGS="-D warnings" cargo +1.97.1 doc --workspace --no-deps --locked
  • actionlint, docs contract, and git diff --check

Gate

This PR is intentionally stacked on PR #17 exact head 80379bc. It remains subject to an independent current-head review, required Checks, and the protected merge rules. No self-approval, merge, or protection bypass is requested.

@coderabbitai

coderabbitai Bot commented Aug 20, 2026

Copy link
Copy Markdown

Important

Review skipped

Auto reviews are disabled on base/target branches other than the default branch.

Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro Plus

Run ID: a0a071fb-1975-407e-beef-a3e9fbf72e82

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • 🔍 Trigger review

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

Copy link
Copy Markdown
Contributor Author

@opencode-agent Review only the exact current head 37382cf against base 80379bc for PR #18. Do not update branches, approve, merge, or bypass protection. Check the forward migration, SQLx embedded-migration behavior, disposable PostgreSQL rehearsal cleanup/connection safety, and whether the documented evidence stays distinct from production-readiness claims.

Copy link
Copy Markdown
Contributor Author

@opencode-agent Review only the exact current head f0a5e55 on PR #18 against base 80379bc. The head adds the required PostgreSQL smoke assertion for audit_event_record_tenant_correlation_idx. Do not update branches, approve, merge, or bypass protection; re-check migration lock/SQLx behavior, rehearsal cleanup/connection safety, and evidence boundaries.

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