[Book Review] Cloud Native Spring In Action: With Spring Boot and Kubernetes
Learn about Spring Boot, Kubernetes, and Cloud Native step by step with a practical project
I don’t know where to begin to write a fair and worthy review for this amazing book. On the other hand, I think writing this review might be a little late because I bought this book more than a year ago when it was in the Manning Early Access Program (MEAP) and read it chapter by chapter when the author was completing it. And fortunately met the author (Thomas Vitale) in person at Spring I/O 2022 conference in Barcelona last year. I admit that I am lazy, I have read this book two times (maybe more!) and have recommended it to several of my friends and colleagues, but I got lazy to write a review for that. But Never late to mend, So let's start.
· Five important aspects of this book ∘ Book structure ∘ Project source code · The content of the book ∘ Part 1: Cloud native fundamentals ∘ Part 2: Cloud native development ∘ Part 3: Cloud native distributed systems ∘ Part 4: Cloud native production ∘ Two important Appendixes ∘ Possible improvements in the book · Final Word

Five important aspects of this book
I believe that these 5 important properties of this book make it special and stand out:
- Thomas Vitale: A seasoned Software Engineer, Cloud Architect, and Conference Speaker who describe every concept in detail, you feel to have a compassionate mentor throughout the book.
- Spring Boot: You will learn Spring Boot with fun by implementing a real Cloud Native application, writing many tests, learning Reactive Spring and Spring Cloud, and engaging with basic concepts in Spring Boot.
- Cloud Native: Learning cloud native concepts with a good balance between theory and practice.
- Kubernetes: You will learn how to develop and deploy cloud native applications in a local cluster and a managed cluster (production) as well, and how to apply continuous deployment using GitOps practices on Kubernetes.
- Polar Bookshop: Having a practical Cloud Native project with several services which getting completed chapter by chapter, will be very helpful for better learning.
These five aspects make this book perfect for every Java developer at any level who wants to learn about Cloud Native or update their knowledge in these areas.
Book structure
The book comprises four parts with a different focus but the same goal. There are also two valuable appendices. Each part concentrates on one main goal but continues to evolve our knowledge about other things.
Project source code
The book accompanies by a GitHub repository that contains code you will learn for each chapter. For each chapter, there are two (for some chapters, three ) folders that contain the completed project from the last chapter (called XX-begin) and one folder for the completed project in the current chapter (called XX-end). In this way, you can follow the project code along each chapter while you are reading the book.
The Polar Bookshop project was implemented based on Java 17 and Spring Boot 2.7 in the book, but the author provides two more implementations (in two branches) based on Spring Boot 3.0.7 and Spring Boot 3.1.0, which is wonderful.
The content of the book
Part 1: Cloud native fundamentals
Part one comprises two chapters. You might think that this part has a lot of theoretical description about cloud computing, cloud native, and microservice architecture, and tempting to skip it, but wait, It would be best if you rethink your decision. Although the first chapter of this part is entirely theoretical without a line of coding, you should not miss the excellent introduction to the cloud native landscape by Thomas Vitale. Even though you already know about the cloud native concept, I highly recommend reading these 30 pages. You will like how Thomas introduced cloud native and its related concept to you.
Do worries, In the first part of the book, in chapter 2, you will start coding and get introduced to the Polar Bookshop project and its requirements and all technology we will use to implement that. After a detailed introduction to cloud native and its concept in chapter one. Chapter 2 starts to describe the Cloud native patterns and technologies like 12 Factors, Spring Boot, Docker, and Kubernetes, by the end of this chapter, you will be able to implement your first service for the polar bookshop application (catalog-service) using Spring Boot, creating a docker image for it and deploy and run a container from that docker image on a local Kubernetes cluster (Minikube).
Part 2: Cloud native development
Part two comprises five chapters, and In fact, it is the continuation of the second chapter (in part one) by expanding the Polar bookshop project and completing the first implemented services (catalog-service) using Spring Boot and Kubernetes (more services will add in Part 3). At the end of this part, we will have one full-fledged service (catalog-service) which connected to a database and provide REST API for future services, or clients and also we can run it and its dependency locally using docker-compose or develop and run it on a local Kubernetes cluster using minikube and Tilt. In addition to that, according to the 12 Factors rules, we will learn how to externalize the configuration of our services to another service using Spring Cloud Config Server . And finally, we will learn how to define a Deployment pipeline with different stages using GitHub Actions to have CI & CD for our project.
One significant advantage of this book for those who want to learn Spring Boot to write cloud native applications is learning how to write tests at all levels (Unit, Integration, and …). This book will teach you how to write different kinds of tests for each layer in the Spring Boot in detail.
Part 3: Cloud native distributed systems
Part three of the book concentrates on the distributed aspect of a cloud native application. During the five chapters in this part, we will learn a lot about patterns and practices related to developing distributed and scalable systems on top of Kubernetes. In this part, in addition to introducing new services for the Polar Bookshop application, we will make it more robust and scalable by using concepts like API gateway, circuit breakers, caching, Asynchronous and non-blocking architectures (WebFlux), timeout, retries, fallback, and more.
In Chapter 10, we will add a new service (Dispatcher Service) to the Polar Bookshop application based on the Event-driven architecture concepts and will learn how to implement and test event-driven applications using the Spring Cloud Function and RabbitMQ .
There are two dedicated chapters in this part to tackle security concerns for the Polar Bookshop application. We will learn about Spring Security, Keycloak, OAuth2, OpenID Connect, data auditing, and more to make our cloud native application secure.
Part 4: Cloud native production
After three parts, we are almost ready to move our cloud native application to production, in the final part, throughout the 4 chapters, we will learn how to prepare our cloud native application for production by configuring monitoring, distributed tracing, logging, and … some configuration will apply on our application some on K8s and some others need to setup new services.
We will learn how to manage configuration and secrets for production in Kubernetes using ConfigMaps , Secrets and Kustomize.
There is also a dedicated chapter for serverless applications using Spring Cloud Function and GraalVM to deploy on Knative.
One of the valuable things in this part for me is applying GitOps strategies and practices with Argo CD.
Two important Appendixes
It is worth mentioning that there are two important appendices in this book that you need to read the first one (appendix A) before starting part 1 (or chapter 2), it will help us to set up our development environment before starting the book. This appendix will introduce us to several useful tools like SDKMAN!, minikube, HTTPie, and more.
Unlike Appendix A, which needs to be read before starting the book, you need to read Appendix B at the end of the book (or chapter 15), when we will learn everything and deploy the Polar Bookshop application on a local minikube cluster. Then we are ready to go for production by deploying our cloud native application on a DigitalOcean managed Kubernetes cluster. In Appendix B, we will learn the required steps to do that.
Possible improvements in the book
So far, I only wrote the benefits and good things about the book. For me, it was tough to find downsides to this book, but at least I can mention some possible improvements that could make me happier than now (maybe in the second edition):
- Use Kafka instead of RabbitMQ to develop an event-driven service.
- Use IaaC like Terraform instead of using the DigitalOcean command line to spawn the Kubernetes cluster and required services.
- More use of Helm in the book.
Final Word
This book covers many techniques and concepts, and I might have missed something in this review. I am sure you will recommend this book after reading it to others.
There are some other book reviews that I wrote. You can read them from the links below:
You can follow me for upcoming stories:
Read my short technical posts on Twitter.





