cqrs-es2-sql

Crates.iocqrs-es2-sql
lib.rscqrs-es2-sql
version0.1.0
sourcesrc
created_at2021-08-14 22:01:03.753617
updated_at2021-08-14 22:01:03.753617
descriptionA SQL implementation of an event store for cqrs-es2.
homepage
repositoryhttps://github.com/brgirgis/cqrs-es2-sql
max_upload_size
id436999
size46,837
Bassem Girgis (brgirgis)

documentation

https://docs.rs/cqrs-es2-sql

README

cqrs-es2-sql

A SQL implementation of the cqrs-es2 stores.

Publish Test Crates.io docs


Installation

[dependencies]
cqrs-es2 = "^0.3"
serde = { version = "^1.0.127", features = ["derive"] }
serde_json = "^1.0.66"
cqrs-es2-sql = "0.1.0"
postgres = { version = "^0.19.1", features = ["with-serde_json-1"] }

Usage

use postgres::{Client, NoTls};
use cqrs_es2_sql::postgres_cqrs;

let connection = Client::connect("postgresql://demo_user:demo_pass@localhost:5432/demo", NoTls).unwrap();
let cqrs = postgres_cqrs(connection, vec![Box::new(my_query)])

Change log

v0.1.0

  • Move from deprecated repo
  • Consolidate store implementations
  • Use cqrs-es2 version 0.4.0

TODO

  • Some additional framework around GenericQueryRepository to simplify event replay.

Demo

A demo application is available here.

Commit count: 0

cargo fmt