|
|
|
|
|
by rswail
747 days ago
|
|
Wrote a public transport ticketing system that processes 100-200K+ trips/day with sub-second push of notification to mobiles of trip/payments. Event driven and CQRS "entities" made logic and processing much easier to create/test/debug. Primary issues:
1. Making sure you focus on the "Nouns" (entities) not the "Verbs".
2. Kafka requiring polling for consumers sucks if you want to "scale to zero".
3. Sharding of event consumers can be complicated.
4. People have trouble understanding the concepts and keep wanting to write "ProcessX" type functions instead of state machines and event handlers.
5. Retry/replay is complicated, better to reverse/replay. Dealing with side effects in replay is also complicated (does a replay generate the output events which trigger state changes in other entities?) Been running now for 6 years, minimal downtime except for maintenance/upgrades. In the process of introducing major new entity and associated changes, most of the system unaffected due to the decoupling. |
|