A Postgres implementation of the
EventStore
trait in cqrs-es.
[dependencies]
postgres-es = "0.1.0"
cqrs-es = "0.1.0"
use postgres::{Connection, TlsMode};
use postgres_es::PostgresCqrs;
let connection = Connection::connect("postgresql://demo_user:demo_pass@localhost:5432/demo", TlsMode::None).unwrap();
let cqrs = postgres_es::postgres_cqrs(connection, vec![Box::new(my_query)])
- Some additional framework around
GenericQueryRepository
to simplify event replay.
A demo application is available here.