Questions tagged [saga]

A pattern that enables a service bus to deal with long-running processes, fault tolerance and scalability.

Long-running business processes exist in many systems. Whether the steps are automated, manual, or a combination, effective handling of these processes is critical.

NServiceBus employs event-driven architectural principles to bake fault-tolerance and scalability into these processes.

The Saga is a pattern that addresses these challenges uncovered by the relational database community years ago, packaged in NServiceBus for ease of use by developers.

MassTransit supports sagas, and Automatonymous is a saga implementation built on top of MassTransit.

497 questions
2
votes
1 answer

Redux saga test select effect

How do I test select effect? My saga depends on the result of the select but each time I am just getting undefined from the saga. Here is what I tried: in my saga: function* loadData() { const foo = yield select((state) => { return…
Adam
  • 3,415
  • 4
  • 30
  • 49
2
votes
1 answer

Multiple distributed event stores for data governance working together

I play around with CQRS/event sourcing for a couple of months now. Currently, I'm having trouble with another experiment I try and hope somebody could help, explain or even hint on another approach than event sourcing. I want to build a distributed…
Florian Bachmann
  • 532
  • 6
  • 14
2
votes
1 answer

MassTransit saga running with prefetch > 1

I have a MassTransit saga state machine (derived from Automatonymous.MassTransitStateMachine) and I'm trying to work around an issue that only manifests when I set the endpoint configuration prefetchCount to a value greater than 1. The issue is that…
Robert
  • 1,487
  • 1
  • 14
  • 26
2
votes
1 answer

Unit testing of Saga handlers in rebus and correlation issues

I have this simple Saga in Rebus: public void MySaga : Saga IAmInitiatedBy IHandleMessages { private IBus bus; private ILog logger; public MySaga(IBus bus, ILog logger) { …
BAD_SEED
  • 4,840
  • 11
  • 53
  • 110
2
votes
1 answer

How do I perform constructor injection with an NServiceBus saga?

If I have a class HelperClass that I'd like to use within a saga, I'd like to be able to inject an IHelperClass into the constructor. The problem I'm running into is that sagas appear to be instantiated with an empty constructor; so while I can…
ksigmund
  • 527
  • 1
  • 6
  • 13
2
votes
1 answer

NServiceBus Saga has no IPersistTimeouts component registered

I have a self-hoted WCF Host (IIS) where I get this exception during the NServiceBus configuration: Exception thrown: 'Autofac.Core.Registration.ComponentNotRegisteredException' in NServiceBus.Core.dll Additional information: The requested service…
John
  • 3,591
  • 8
  • 44
  • 72
2
votes
1 answer

Should sagas be used to persist progress in execution of a handler?

I have a handler whose job it is to take a list of objects, and for each item in that list of objects, Publish an event. That may look something like the code below: Handle(PublishListMessage message) { foreach(var entry in message.List) { …
mike
  • 1,318
  • 3
  • 21
  • 41
2
votes
1 answer

Saga Wait for Status value

I have a Saga which should wait for a specific Database-Value to be changed. How do I achieve this? Example: public partial class OrderSaga : Saga, IHandleMessages { public void Handle(FinishOrder message) { …
Ole Albers
  • 8,715
  • 10
  • 73
  • 166
2
votes
2 answers

NEventStore: Sagas, Commands and not Losing Them

NEventStore: 5.1 Simple setup: WebApp (Asp.NET 4.5) == command-side I'm searching for the "right" way for not losing commands, with an eye on sagas/process-managers which maybe would wait endlessly for an event produced from a command that was…
David Rettenbacher
  • 5,088
  • 2
  • 36
  • 45
2
votes
1 answer

How to solve "Error: tool" with RSAGA?

I am using R 3.1.1 on Ubuntu 14 64 bit version. I installed SAGA GIS 2.1.2 and RSAGA 0.93-6. So far all seems to work fine. rsaga.env() works, I use: work_env <- rsaga.env(modules='/usr/lib/x86_64-linux-gnu/saga/') because on the 64 bit the…
2
votes
1 answer

NServiceBus Saga handle a message-type multiple times gives concurrency exception

We have a NServiceBus implementation that handles multiple message-types: public class StateCoordinator : Saga, IAmStartedByMessages, …
EagleBP
  • 131
  • 8
2
votes
1 answer

NServiceBus and nvarchar(max)

My Saga class is as follows: public class SagaData : IContainSagaData { [Unique] public virtual string SagaKey { get; set; } public virtual string Data { get; set; } #region IContainSagaData public virtual Guid Id { get; set;…
bpiec
  • 1,561
  • 3
  • 23
  • 38
2
votes
3 answers

Conditionally start Saga

I have two types of events : PersonChanged PersonAddressChanged. Both of them are being published also when a new Person (and a new address) is created (kind of create or update). When a new person is created two events are published:…
bpiec
  • 1,561
  • 3
  • 23
  • 38
2
votes
1 answer

Do Sagas work with Unobtrusive Mode?

I have an endpoint, called UploadService, that contains a saga started by a command defined in another assembly. The commands in that assembly are registered in the endpoint's initialization via the following lines: public class…
Andrew Church
  • 1,391
  • 11
  • 13
2
votes
1 answer

NServiceBus SagaData persistance issue with NHibernate around List

I am getting error when i trying to store this sagadata and that too because of List. As soon as i remove this List it can store the data. public virtual Guid Id { get; set; } public virtual string Originator { get; set; } public virtual string…
Miral
  • 5,968
  • 16
  • 57
  • 85