boltdb

package
v0.0.0-...-f0f3bdc Latest Latest
Warning

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

Go to latest
Published: Dec 27, 2022 License: MIT Imports: 7 Imported by: 1

Documentation

Index

Constants

View Source
const (
	EVENTS_BUCKET         = "EVENTS"
	EVENT_METADATA_BUCKET = "EVENT_METADATA"
	AGGREGATES_BUCKET     = "AGGREGATES_BUCKET"
)
View Source
const OFFSET_BUCKET = "OFFSETS"

Variables

This section is empty.

Functions

func NewOffsetStore

func NewOffsetStore(path string) cqrs.OffsetStore

New bolt offset store

Types

type BoltEventStore

type BoltEventStore struct {
	// contains filtered or unexported fields
}

InMemory implementation of the event store

func NewBoltStore

func NewBoltStore(path string) *BoltEventStore

func (*BoltEventStore) GetEvent

func (store *BoltEventStore) GetEvent(id string) Event

func (*BoltEventStore) GetEventMetaDataFrom

func (store *BoltEventStore) GetEventMetaDataFrom(offset, count int) []EventMetaData

func (*BoltEventStore) GetEvents

func (store *BoltEventStore) GetEvents(aggregateId string) []Event

func (*BoltEventStore) SaveEvents

func (store *BoltEventStore) SaveEvents(aggregateId string, events []Event) error

type BoltOffsetStore

type BoltOffsetStore struct {
	// contains filtered or unexported fields
}

func (*BoltOffsetStore) GetLastOffset

func (store *BoltOffsetStore) GetLastOffset() (int, error)

func (*BoltOffsetStore) SaveOffset

func (store *BoltOffsetStore) SaveOffset(value int) error

Jump to

Keyboard shortcuts

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