Event: Something that happens that the program can respond to: a button click, an HTTP request, a file change, a timer firing, a message arriving in a queue. An event is something that happens which a program can react to: a click, a key press, an incoming HTTP request, a file being saved, a timer firing or a message arriving in a queue.
Event-driven code is organised around these moments. Instead of one long sequence of steps, you write small pieces of code that run when a specific event occurs.
What should you keep in mind with Event?
In web applications, events also describe business moments, such as OrderPaid or UserRegistered. Code that sends a confirmation email, updates statistics or notifies the warehouse listens for that event. The order code itself stays simple and does not need to know about all those follow-up tasks. The trade-off is that the full flow is spread out, so clear event names and a list of listeners help a lot.
Implement proven backend architecture patterns including Clean Architecture, Hexagonal Architecture, and Domain-Driven Design. Use this skill when designing clean architecture for a new microservice, when refactoring a monolith to use bounded contexts, when implementing hexagonal or onion architecture patterns, or when debugging dependency cycles between application layers.
Implement Command Query Responsibility Segregation for scalable architectures. Use when separating read and write models, optimizing query performance, or building event-sourced systems.