outboxcore

package
v2.0.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: May 1, 2026 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

View Source
const (
	StatusPending    = "pending"
	StatusPublishing = "publishing"
	StatusPublished  = "published"
	StatusFailed     = "failed"

	DefaultPublishingStaleFor = time.Minute
	DefaultRelayRetryDelay    = 10 * time.Second
)

Variables

This section is empty.

Functions

func BuildStatusSnapshot

func BuildStatusSnapshot(store string, now time.Time, observations []StatusObservation) outboxport.StatusSnapshot

func UnfinishedStatuses

func UnfinishedStatuses() []string

Types

type BuildRecordsOptions

type BuildRecordsOptions struct {
	Events   []event.DomainEvent
	Resolver eventcatalog.TopicResolver
	Delivery eventcatalog.DeliveryClassResolver
	Now      time.Time
}

type Record

type Record struct {
	EventID       string
	EventType     string
	AggregateType string
	AggregateID   string
	TopicName     string
	PayloadJSON   string
	Status        string
	AttemptCount  int
	NextAttemptAt time.Time
	CreatedAt     time.Time
	UpdatedAt     time.Time
}

func BuildRecords

func BuildRecords(opts BuildRecordsOptions) ([]Record, error)

type StatusObservation

type StatusObservation struct {
	Status          string
	Count           int64
	OldestCreatedAt *time.Time
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL