feat: centralize NATS message broker implementation in infra and abstract its usage in API and worker

This commit is contained in:
2026-01-02 01:22:18 +01:00
parent 064d2ae748
commit 328f2f2fb2
14 changed files with 158 additions and 110 deletions

View File

@@ -7,11 +7,10 @@ edition = "2024"
default = ["sqlite", "smart-features"]
sqlite = ["notes-infra/sqlite", "sqlx/sqlite"]
# postgres = ["notes-infra/postgres", "sqlx/postgres"]
smart-features = ["notes-infra/smart-features"]
smart-features = ["notes-infra/smart-features", "notes-infra/broker-nats"]
[dependencies]
anyhow = "1.0.100"
async-nats = "0.45.0"
notes-domain = { path = "../notes-domain" }
notes-infra = { path = "../notes-infra", default-features = false }
serde = { version = "1.0.228", features = ["derive"] }