Domain events and version control without CQRS

Hi I have the following script that I don’t understand how to get a possible sequence:

  • User 1 uses ui-based Task to change client name
  • Operation with application services in an aggregate
  • Aggregate fire event on the changed name changed
  • the bus sends a message using nservicebus
  • NServicebus Service
  • User 2 receives aggregate and call change address
  • Aggregate operation is called
  • Domain Event
  • Message on the bus
  • Bus reboot
  • Message 2 is selected first.
  • Processing message 2 and other restricted context updated with a new address
  • Message 1 is selected now, which is incorrect.
  • What is happening now

At 13 would there be an optimistic concurrency error if we pass the aggregate version in the event?

, Message 1 new . ?

, . .

. concurrency .

CQRS , . , , , .

Blair

+5
4

, . , . -, , , . TCP 1981 http://www.ietf.org/rfc/rfc793.txt:)

+3

. , ( ). , , . , .

/:

, , 2 . , . . , , , , 2 ( ) ---:)

, , .

, , concurrency - . , , , . .

, , /.

. ChangeAddressCommand LastAddressChange, , .

0

NServiceBus . OP IBus.HandleCurrentMessageLater() , . , , , .

saga, , , . , BC. , 1 2 . , , 2. 2 3 , , 3. NServiceBus BC 2 1, , 1 , , 2. , . 1 1, 2 . , .

0
source

According to this , you should ask yourself:

What is the impact of business on failure?

In your current case, you have this problem once per million requests. I do not think that this would have a huge impact on the business if you accepted both requests as valid.

0
source

All Articles