feat(wfe-postgres): add PostgreSQL persistence provider

PostgresPersistenceProvider using sqlx with wfc schema. JSONB for
complex fields, TIMESTAMPTZ for dates. Transactions for atomicity.
Proper error propagation on deserialization (no unwrap_or_default).
Status conversion returns Result for unknown values.
This commit is contained in:
2026-03-25 20:13:44 +00:00
parent f39766cc3d
commit b2c37701b1
3 changed files with 968 additions and 0 deletions

24
wfe-postgres/Cargo.toml Normal file
View File

@@ -0,0 +1,24 @@
[package]
name = "wfe-postgres"
version.workspace = true
edition.workspace = true
license.workspace = true
description = "PostgreSQL persistence provider for WFE"
[dependencies]
wfe-core = { workspace = true }
sqlx = { workspace = true }
tokio = { workspace = true }
serde = { workspace = true }
serde_json = { workspace = true }
async-trait = { workspace = true }
uuid = { workspace = true }
chrono = { workspace = true }
thiserror = { workspace = true }
tracing = { workspace = true }
[dev-dependencies]
wfe-core = { workspace = true, features = ["test-support"] }
pretty_assertions = { workspace = true }
rstest = { workspace = true }
tokio = { workspace = true, features = ["test-util"] }