Event-driven architecture (EDA) è un design dove i componenti comunicano producendo e reagendo a eventi (qualcosa che è accaduto) — piuttosto che tramite chiamate dirette. Abilita il loose coupling, la scalabilità e la reattività, ed è comune nei moderni sistemi distribuiti.
Cosa è l'event-driven architecture
Components communicate via EVENTS (a notification that something happened):
→ PRODUCERS emit events ("order placed", "user signed up") without knowing who handles them
→ CONSUMERS react to events they care about (asynchronously)
→ an event BROKER/bus (Kafka, message queue) routes events
→ components are DECOUPLED → they react to events, not call each other directly.
