Postgres connector for aett event store
Project description
Æt (Aett) is an Event Store for Python
Aett Postgres provides the ability to store and retrieve events from a Postgres.
Usage
To create an event stream to manage events, you can use the PersistenceManagement
class.
import psycopg
from aett.postgres.EventStore import PersistenceManagement
# Set up a new event store
mgmt = PersistenceManagement(psycopg.connect("host=localhost port=5432 dbname=aett user=aett password=aett"))
mgmt.initialize()
# Drop the store
mgmt.drop()
The package also provides CommitStore
and SnapshotStore
classes that can be used to store and retrieve events. They
can be instantiated by providing a Postgres database connection and specifying the configured table name.
from aett.postgres.EventStore import CommitStore, SnapshotStore
import pymongo.database
snapshot_store = SnapshotStore(psycopg.connect("host=localhost port=5432 dbname=aett user=aett password=aett"))
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
aett_postgres-2.0.1.tar.gz
(6.2 kB
view hashes)
Built Distribution
Close
Hashes for aett_postgres-2.0.1-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 7d79a67b7021b0d6113b88753b3da729c6815d64e5aefd5471f890dc19372f6f |
|
MD5 | 674a2641dc126785022102cb0a1bfd73 |
|
BLAKE2b-256 | b8aae3667741520b31b10151884baea0ee5ae098961c6ed0927551b6415b9d48 |