0af749c92e
This commit wraps memdb.DB with a changeTrackerDB, which is a thin wrapper around memdb.DB which enables go-memdb's TrackChanges on all write transactions. When the transaction is comitted the changes are sent to an eventPublisher which will be used to create and emit change events. debugging TestFSM_ReconcileSummaries wip revert back rebase revert back rebase fix snapshot to actually use a snapshot
14 lines
265 B
Go
14 lines
265 B
Go
package event
|
|
|
|
type Event struct {
|
|
Topic string
|
|
Key string
|
|
Index uint64
|
|
Payload interface{}
|
|
}
|
|
|
|
type EventPublisher struct{}
|
|
|
|
func NewPublisher() *EventPublisher { return &EventPublisher{} }
|
|
func (e EventPublisher) Publish(events []Event) {}
|