Documentation ¶
Overview ¶
Package julio enables to use PostgreSQL as storage for a simple JSON based event sourcing.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Filter ¶
type Filter struct { Sqlizer squirrel.Sqlizer Updates bool OnlyNew bool // subscribe only to new events, skip the "historic" Paginate bool // will increase performance on big queries, but is slow on small queries StartAt uint64 }
Filter defines the SQL where predicate to filter existing and new rows alike.
type Julio ¶
Julio wraps a PostgreSQL database connection to be used for event sourcing. The underlying connection is exposed as DB.
func (*Julio) Add ¶
Add adds a new event entry to the given table. The payload v is json serialized in the database.
type Row ¶
type Row struct { ID int Data json.RawMessage }
Row is a single row or event in the database
Click to show internal directories.
Click to hide internal directories.