user1477327
user1477327

Reputation: 164

Event driven design orchestration

I have a question about an event driven design architecture.

I have a server application that contains many domain services. each service is a WCF service, and I want the services to communicate using raising events via a dedicated pub-sub infrastructure that I've created.

Now everything works well, but I have a question regarding the orchestration..

I have a manager service which accepts calls from the consumers and starts the process, sending a message to component A which in turn sends a message to component B and so on.

Eventually some of these services raise events for the manager service which keeps no state of incoming requests.

What is the best way to orchestrate or manage this flow?

Thanks

Upvotes: 1

Views: 621

Answers (1)

eulerfx
eulerfx

Reputation: 37709

Take a look at NServiceBus and NServiceBus sagas in particular. A saga (the meaning in NSB is more akin to 'process manager') maintains state and correlates messages by some ID. In your case, the manager service is a sort of saga. It should maintain sate for each process that it manages. This state should be keyed by a correlation ID to be shared by all messages sent between components.

Upvotes: 2

Related Questions