In the modern IT world we are having millions of users generating billions of events, part of which is supposed to be a part of our business. We as developers should process these events, store it and digest. One of the most obvious answers is to use microservices for that. But to squeeze maximum out of this architecture usual synchronous request-response model may be not good enough. A synchronous approach is not efficient enough, and can lead to massive “clogging” of data on a way as well as decreased user experience and reputation costs.
For solving this problem we can use an event-driven fully asynchronous approach by using the pub-sub pattern. The key concept around event-driven architectures is to extract this pattern from a single microservice and build a whole system around it. For showing this case we will use Google Cloud Serverless, which fits well for this type of application. Let’s make an overview of event-driven architecture and its benefits for extensibility, also taking a short walk around GCP aids for event-driven, reliable, and scalable apps.