The Author Online Book Forums are Moving

The Author Online Book Forums will soon redirect to Manning's liveBook and liveVideo. All book forum content will migrate to liveBook's discussion forum and all video forum content will migrate to liveVideo. Log in to liveBook or liveVideo with your Manning credentials to join the discussion!

Thank you for your engagement in the AoF over the years! We look forward to offering you a more enhanced forum experience.

Tim P (9) [Avatar] Offline
Your example (2 instructions to reduce by 2000ft) is not good because it's a relative instruction based on internal state. But why not simply issue an instruction to reduce altitude to 3000ft. Then your commands become unambiguous.

Also - automatic rejection based on aggregate version number can lead to queuing problems. Let us suppose that I open booking for a show at 10am and there is huge demand.
Immediately I get 30 requests all based on version 0.
One gets through.
The other 29 are rejected and have to be re-submitted. I send all those validation failures and the users resubmit based on the current state - now version 1. So this time someone else gets accepted, but 28 get rejected. Eventually I have to deal with a total of O(n2) requests. Also the position in the queue no longer depends on the original request ordering - and quite possibly people booking in positions 31+ sneak in first.

To take another example from your airplane aggregate - I tell them to reduce to 3000ft because there's a collision risk but in the meantime they've served a meal and the kitchen stock of chicken chasseur has been decreased by 1, so the request is rejected ...

Versioning may work in some cases but you can't present it as a panacea to conflict resolution.