Skip to content

0.6.0 Persistent storage with PostgreSQL and Nats

Compare
Choose a tag to compare
@mvniekerk mvniekerk released this 05 Apr 21:27
· 102 commits to main since this release

Overview

This release brings persistent storage using either PostgreSQL or Nats. There's also a major refactoring of the innards of the library, but keeping the API (mostly) the same.

Thank you @vkill and @hgzimmerman for your contributions.

Migration

See the Migration Docs. Also check out the Nats integration and PostgreSQL integration docs if you want to use any of the persistent storage modules.

Examples

Nats

Setup a running Nats instance with Jetream enabled:

docker run --rm -it -p 4222:4222 -p 6222:6222 -p 7222:7222 -p 8222:8222 nats -js -DV

Then run the example:

cargo run --example nats --features="nats_storage tracing-subscriber"

PostgreSQL

Setup a running PostgreSQL instance:

docker run --rm -it -p 5432:5432 -e POSTGRES_USER="postgres" -e POSTGRES_PASSWORD="" -e POSTGRES_HOST_AUTH_METHOD="trust" postgres:14.1

Then run the example:

POSTGRES_INIT_METADATA=true POSTGRES_INIT_NOTIFICATIONS=true cargo run --example postgres --features="postgres_storage tracing-subscriber"