0

I currently configured rebus to direct all messages in MyMessages assembly to the process managers input queue. Suppose in MyMessage assembly I have a message called SomethingHappened which will be used to trigger other actions in process managers (e.g. DoSomethingElse). However, I also want to subscribe SomethingHappened locally (in the same queue) to update the database. So the workflow will look like:

  1. User trigger the action DoSomething in the UI
  2. The handler of DoSomething updates the object state and publish events SomethingHappened internally (in memory collection of uncommitted events)
  3. SomethingHappened events get published by rebus to the queue by go through all uncomitted events in the object
  4. Handle SomethingHappened locally to update database
  5. Handle SomethingHappened remotely by saga to trigger SomethingElseHappened

Is this possible to be configured in rebus?

The rebus configuration I currently have:

<rebus inputQueue="input" errorQueue="error" workers="1" maxRetries="5">
    <endpoints>
        <add messages="MyMessages" endpoint="processManagers.input"/>
    </endpoints>
</rebus>

Thank You

Yin

Yin
  • 301
  • 2
  • 11
  • My mistake. I should change the endpoint to configuration to input. And then never, never subscribe to commands. : ) – Yin Aug 19 '14 at 23:19

1 Answers1

0

My mistake. I should change the endpoint to configuration to input. And then never, never subscribe to commands. :)

<rebus inputQueue="input" errorQueue="error" workers="1" maxRetries="5">
    <endpoints>
       <add messages="MyMessages" endpoint="input"/>
    </endpoints>
</rebus>
Yin
  • 301
  • 2
  • 11