Skip to content

Search EricksonLopez.* Ecosystem

Type a library name, NuGet package ID, .NET type, or architectural concept to search across the portal.

Core Concepts — Sagas, Transitions, Compensation & Effects

EricksonLopez.Processes separates deterministic state-machine logic from storage concurrency and side-effect dispatching.

  • State & identity: Domain state records implement IProcessState, while process metadata uses strongly-typed ProcessId, CorrelationId, CausationId, MessageId, ProcessType, ProcessVersion, and Revision.
  • Transition factories: Return .Advance(...), .Suspend(...), .Complete(...), .Compensate(state, compensationActions), .Compensated(...), or .Fail(...). Note that Compensate(TState state, IEnumerable<CompensationAction>? compensationActions = null) accepts only state and actions (there is no reason: parameter).
  • ProcessEffect: Transitions emit pure intent objects (Command, Event, ScheduleTimeout, Compensation) executed outside the storage lock via Processes.Outbox, Processes.Mediator, or Processes.Events.
  • LIFO compensation: Forward steps record CompensationStep entries; failures trigger ICompensationHandler<TState>.CompensateAsync in reverse order up to MaxCompensations (1000 default).
  • Roslyn Analyzers (EricksonLopez.Processes.Analyzers): PROC001–PROC003 verify [ProcessDefinition]/[SagaDefinition] contracts and ensure at least one reachable terminal transition exists.