Documentation
¶
Overview ¶
Package outbox delivers PostgreSQL outbox events to a durable publisher. Delivery is at-least-once: a crash after broker acknowledgement and before the database acknowledgement may publish a duplicate.
Index ¶
Constants ¶
View Source
const ( StreamName = "FENCED_EVENTS" SubjectPrefix = "fenced.events" )
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Dispatcher ¶
type Dispatcher struct {
// contains filtered or unexported fields
}
func NewDispatcher ¶
func NewDispatcher(repository Repository, publisher Publisher, id string, batch int, lockTTL time.Duration) *Dispatcher
type JetStreamPublisher ¶
type JetStreamPublisher struct {
// contains filtered or unexported fields
}
func NewJetStreamPublisher ¶
func NewJetStreamPublisher(js jetstream.JetStream) *JetStreamPublisher
func (*JetStreamPublisher) Publish ¶
func (p *JetStreamPublisher) Publish(ctx context.Context, event store.OutboxEvent) error
Click to show internal directories.
Click to hide internal directories.