sagalogs

package
v0.0.1-alpha Latest Latest
Warning

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

Go to latest
Published: Feb 28, 2022 License: Apache-2.0 Imports: 11 Imported by: 0

Documentation

Overview

Package sagalogs provides implementations of SagaLog.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func MakeFileSagaLog

func MakeFileSagaLog(dirName string) (*fileSagaLog, error)

Creates a FileSagaLog with files stored at the specified directory If the directory does not exist it will create it.

func MakeInMemorySagaCoordinator

func MakeInMemorySagaCoordinator(gcExpiration time.Duration, gcInterval time.Duration, stat stats.StatsReceiver) saga.SagaCoordinator

Returns an Instance of a Saga based on an inMemorySagaLog. This is an in-memory impl, and is not durable. Implements GC of whole sagas based on time expiration regardless of Saga state. GC should be set at a duration that realistically will not purge active Sagas. gcExpiration: duration after which a Saga was created, it will be deleted.

A zero duration is interpretted as "never gc" (the Log will eventually consume all memory).

gcInterval: duration interval at which GC runs.

func MakeInMemorySagaCoordinatorNoGC

func MakeInMemorySagaCoordinatorNoGC(stat stats.StatsReceiver) saga.SagaCoordinator

Shorthand creator function to create a non-GCing SagaLog with Coordinator

func MakeInMemorySagaLog

func MakeInMemorySagaLog(gcExpiration time.Duration, gcInterval time.Duration) saga.SagaLog

Make an InMemorySagaLog with specified GC expiration and interval duration.

func MakeInMemorySagaLogNoGC

func MakeInMemorySagaLogNoGC() saga.SagaLog

Shorthand creator function to create a non-GCing SagaLog

Types

This section is empty.

Jump to

Keyboard shortcuts

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