Chapter 9. Developing Microservices
Let’s put to work some of the techniques we’ve been discussing and implement a sample multimicroservices project. The implementation of the microservices in this sample project will be greatly simplified. We will show just enough code to suffice for demonstration purposes, but the steps and approaches we’ll discuss can be directly applied on much larger, real projects.
We will start by identifying fitting candidates for microservices based on a bounded contexts analysis using Event Storming, similar to the process described in Chapter 4. Next we’ll go through the seven steps of the SEED(S) design methodology that we discussed in Chapter 3, culminating in writing the code for both of the sample microservices. In the implementation of these services we will employ the data-modeling guidance from Chapter 5. And last, but not least, we will show how a user-friendly development environment for the microservices is properly set up and configured, applying many of the recommendations from Chapter 8, including the creation of an umbrella project—a way to execute multiple microservices together in a developer workspace.
Designing Microservice Endpoints
Let’s assume that an Event Storming session that you conducted for a flight management software product identified two major bounded contexts:
-
Flights management
-
Reservations management
As we discussed in Chapter 4, in the initial stages it pays off to design microservices in a coarse-grained way. ...
Get Microservices: Up and Running now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.