Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Config ¶
Config holds the state for a PostgreSQL DB config.
func NewConfigFromEnvironment ¶ added in v0.6.0
NewConfigFromEnvironment loads a Postgres config from environment variables.
func (Config) DataSourceName ¶
DataSourceName returns the DSN for a PostgreSQL DB.
type JsonSerializer ¶
type JsonSerializer interface {
rangedb.EventBinder
rangedb.EventTypeIdentifier
}
JsonSerializer defines the interface to bind events and identify event types.
type Option ¶
type Option func(*postgresStore)
Option defines functional option parameters for postgresStore.
func WithPgNotify ¶ added in v0.6.0
func WithPgNotify() Option
WithPgNotify enables pg_notify() for notifying subscribers.
type PostgresJsonRecord ¶ added in v0.6.0
type PostgresJsonRecord struct {
AggregateType string `json:"aggregatetype"`
AggregateID string `json:"aggregateid"`
GlobalSequenceNumber uint64 `json:"globalsequencenumber"`
StreamSequenceNumber uint64 `json:"streamsequencenumber"`
InsertTimestamp uint64 `json:"inserttimestamp"`
EventID string `json:"eventid"`
EventType string `json:"eventtype"`
Data string `json:"data"`
Metadata string `json:"metadata"`
}
PostgresJsonRecord holds a JSON record sent via pg_notify.
Click to show internal directories.
Click to hide internal directories.