Booking

The booking flows have very different characteristics and requirements than Search. More than performance, reliability is the main requirement here. If the customer has made a payment, then they should get the reservation. The good thing, though, is that booking is always a fraction of your searches, so you do not have the stringent performance requirements that we saw for Search.

Additionally, there is a workflow associated with booking. Once the payment is made, the system needs to make a reservation with the seller, email the customer, and so on. We will be designing an Event-Driven Architecture (EDA) pattern to handle booking. The flow should be similar to flights and hotels, so we can deep-dive into the hotels' booking flow to glean insights.

The high-level architecture is depicted through the following diagram:

The backbone of the architecture is the messaging layer. In the example implementation here, we will be using Kafka. It is responsible for relaying messaging between various microservices that drive various stages of the booking process. The following sections will go into this in detail.

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset