refactor(storage)!: leave database coordination to applications #22

Merged
thesimplekid merged 1 commit from simplify/application-storage into main 2026-10-09 16:37:56 +00:00
Owner

Remove the bundled PostgreSQL and lease implementation so applications own database setup, migrations, and worker coordination. Keep the PaymentStore, CashuJournal, and LightningJournal traits and embedded redb implementation, with the coordination and wallet-ownership contracts documented.

This removes the PostgreSQL feature, dependencies, migration, test harness, and CI job. Applications supplying storage must coordinate both journal and wallet writes during ownership transfer.

Validation: workspace formatting, Clippy, tests, documentation, cargo-deny, and native Nix checks passed. The complete dependent stack also passed 78 tests and the real Bitcoin/LDK regtest.

Remove the bundled PostgreSQL and lease implementation so applications own database setup, migrations, and worker coordination. Keep the PaymentStore, CashuJournal, and LightningJournal traits and embedded redb implementation, with the coordination and wallet-ownership contracts documented. This removes the PostgreSQL feature, dependencies, migration, test harness, and CI job. Applications supplying storage must coordinate both journal and wallet writes during ownership transfer. Validation: workspace formatting, Clippy, tests, documentation, cargo-deny, and native Nix checks passed. The complete dependent stack also passed 78 tests and the real Bitcoin/LDK regtest.
refactor(storage)!: leave database coordination to applications
Some checks failed
Checks / format (push) Successful in 1m10s
Checks / cdk-compatible (push) Failing after 12m47s
Checks / checks (push) Failing after 17m45s
Checks / dependencies (push) Successful in 1m18s
Checks / dependencies (pull_request) Successful in 1m4s
Checks / checks (pull_request) Failing after 17m58s
Checks / format (pull_request) Successful in 1m12s
Checks / cdk-compatible (pull_request) Successful in 13m34s
71c0f5b77a
Keep the storage traits, embedded redb adapter and reusable contract tests.
Remove the bundled PostgreSQL backend, lease workers, wallet fencing hooks,
and their dependencies, development scripts and CI jobs.

Document application ownership of database setup and exclusive wallet access,
including fencing of journal and wallet writes during distributed failover.

BREAKING CHANGE: Remove the postgres feature, PostgresStore, lease errors,
and PaymentStore wallet validation hooks. Applications needing PostgreSQL
must supply their own storage implementation and worker coordination.
Sign in to join this conversation.
No reviewers
No labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
thesimplekid/satsettle!22
No description provided.