ff-backend-postgres 0.11.0

FlowFabric EngineBackend impl — Postgres backend (RFC-v0.7, Wave 0 scaffold)
Documentation
[package]
name = "ff-backend-postgres"
version.workspace = true
edition.workspace = true
license.workspace = true
authors.workspace = true
repository.workspace = true
homepage.workspace = true
keywords.workspace = true
categories.workspace = true
description = "FlowFabric EngineBackend impl — Postgres backend (RFC-v0.7, Wave 0 scaffold)"

[features]
# Mirror ff-core's `core` + `streaming` features so the backend's
# method-gate `#[cfg]`s line up with the trait surface. `core` is
# default-on (ff-core's `core` is always-needed for the minimal
# write surface; ff-backend-valkey takes the same stance via its
# hard ff-core feature activation). `streaming` tracks ff-core's
# `streaming` default.
default = ["core", "streaming"]
core = ["ff-core/core"]
streaming = ["ff-core/streaming"]
# Issue #154 — enable real OTEL metric emission via `ff-observability`.
# Off by default; mirrors `ff-backend-valkey`.
observability = ["ff-observability/enabled"]

[dependencies]
# Wave 0: `core`, `suspension`, `budget` match ff-backend-valkey's
# ff-core feature set so the Postgres backend honours the same
# `EngineBackend` method surface.
ff-core = { version = "0.11.0", path = "../ff-core", default-features = false, features = ["core", "suspension", "budget"] }
# Always-present observability shim (no-op unless `observability`
# feature flips the shim to real OTEL). Mirrors ff-backend-valkey.
ff-observability = { workspace = true }

# Postgres transport. sqlx with tokio-rustls + the macros feature
# (enables `sqlx::migrate!` compile-time migration loading).
sqlx = { workspace = true, features = ["postgres", "runtime-tokio-rustls", "macros", "migrate", "uuid", "chrono", "json"] }

async-trait = { workspace = true }
tokio = { workspace = true }
tracing = { workspace = true }
futures-core = { workspace = true }
thiserror = { workspace = true }
serde_json = { workspace = true }
uuid = { workspace = true }

# Wave 4 Agent D (suspend + signal): Rust-side HMAC sign/verify for
# waitpoint tokens. First server-side HMAC code in the workspace
# (Valkey backend signs inside Lua). Deliberately scoped to this
# crate rather than ff-core so parallel Wave-4 agents don't re-lint
# ff-core's dep graph mid-flight; future refactor can hoist.
hmac = "0.12"
sha2 = "0.10"
hex = "0.4"

[dev-dependencies]
tokio = { workspace = true, features = ["macros", "rt-multi-thread"] }
futures = { workspace = true }
uuid = { workspace = true, features = ["v4"] }