stores

package
v0.0.0-...-a50e536 Latest Latest
Warning

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

Go to latest
Published: Apr 11, 2019 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewInMemoryStore

func NewInMemoryStore() saga.Store

NewInMemoryStore is a factory method for the InMemorySagaStore

Types

type InMemorySagaStore

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

InMemorySagaStore stores the saga instances in-memory, not intended for production use

func (*InMemorySagaStore) DeleteSaga

func (store *InMemorySagaStore) DeleteSaga(tx *sql.Tx, instance *saga.Instance) error

DeleteSaga implements SagaStore.DeleteSaga

func (*InMemorySagaStore) GetSagaByID

func (store *InMemorySagaStore) GetSagaByID(tx *sql.Tx, sagaID string) (*saga.Instance, error)

GetSagaByID implements SagaStore.GetSagaByID

func (*InMemorySagaStore) GetSagasByType

func (store *InMemorySagaStore) GetSagasByType(tx *sql.Tx, t reflect.Type) ([]*saga.Instance, error)

GetSagasByType implements SagaStore.GetSagasByType

func (*InMemorySagaStore) Purge

func (store *InMemorySagaStore) Purge() error

Purge is used for nothing in this case since the store is not persisted use pgstore or mysqlstore

func (*InMemorySagaStore) RegisterSagaType

func (store *InMemorySagaStore) RegisterSagaType(saga gbus.Saga)

RegisterSagaType implements SagaStore.RegisterSagaType

func (*InMemorySagaStore) SaveNewSaga

func (store *InMemorySagaStore) SaveNewSaga(tx *sql.Tx, sagaType reflect.Type, newInstance *saga.Instance) error

SaveNewSaga implements SagaStore.SaveNewSaga

func (*InMemorySagaStore) UpdateSaga

func (store *InMemorySagaStore) UpdateSaga(tx *sql.Tx, instance *saga.Instance) error

UpdateSaga implements SagaStore.UpdateSaga

Jump to

Keyboard shortcuts

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