Documentation
¶
Overview ¶
Package idempotencycommand provides durable named command and source-record import execution with bounded result replay.
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ( // ErrInProgress reports an unexpired owner for the source record. ErrInProgress = errors.New("idempotencycommand: operation in progress") // ErrConflict reports reuse of a source identity for different input. ErrConflict = errors.New("idempotencycommand: source fingerprint conflict") // ErrTerminalFailure reports a deliberately persisted permanent failure. ErrTerminalFailure = errors.New("idempotencycommand: operation terminally failed") )
Functions ¶
This section is empty.
Types ¶
type Options ¶
type Options struct {
Service *idempotency.Service
Lease time.Duration
TransitionTimeout time.Duration
}
Options configures command leases and failed-handler cleanup.
type Request ¶
type Request struct {
Namespace string
Tenant string
Name string
Caller string
SourceID string
Fingerprint idempotency.Fingerprint
}
Request identifies a named command or one record in an import source.
type Result ¶
type Result struct {
Outcome idempotency.Outcome
Result []byte
Metadata map[string]string
Replayed bool
}
Result reports the semantic outcome and bounded replay data.
Click to show internal directories.
Click to hide internal directories.