Intent-Code Divergence
Medium
- Confidence
- 97% confidence
- Finding
- The DynamoDB example presents an append API with an expected_version parameter, but the implementation uses batch_writer without any conditional expressions, so concurrent writers can overwrite append assumptions and create duplicate or out-of-order logical versions. In an event store, missing optimistic concurrency and idempotency directly undermine stream integrity, allowing lost updates, duplicated events, and corrupted aggregate state.
