Search icon CANCEL
Arrow left icon
Explore Products
Best Sellers
New Releases
Books
Videos
Audiobooks
Learning Hub
Conferences
Free Learning
Arrow right icon
Arrow up icon
GO TO TOP
Hands-On Microservices with Spring Boot and Spring Cloud

You're reading from   Hands-On Microservices with Spring Boot and Spring Cloud Build and deploy Java microservices using Spring Cloud, Istio, and Kubernetes

Arrow left icon
Product type Paperback
Published in Sep 2019
Publisher Packt
ISBN-13 9781789613476
Length 668 pages
Edition 1st Edition
Languages
Tools
Arrow right icon
Author (1):
Arrow left icon
Magnus Larsson AB Magnus Larsson AB
Author Profile Icon Magnus Larsson AB
Magnus Larsson AB
Arrow right icon
View More author details
Toc

Table of Contents (25) Chapters Close

Preface 1. Section 1: Getting Started with Microservice Development Using Spring Boot
2. Introduction to Microservices FREE CHAPTER 3. Introduction to Spring Boot 4. Creating a Set of Cooperating Microservices 5. Deploying Our Microservices Using Docker 6. Adding an API Description Using OpenAPI/Swagger 7. Adding Persistence 8. Developing Reactive Microservices 9. Section 2: Leveraging Spring Cloud to Manage Microservices
10. Introduction to Spring Cloud 11. Adding Service Discovery Using Netflix Eureka and Ribbon 12. Using Spring Cloud Gateway to Hide Microservices Behind an Edge Server 13. Securing Access to APIs 14. Centralized Configuration 15. Improving Resilience Using Resilience4j 16. Understanding Distributed Tracing 17. Section 3: Developing Lightweight Microservices Using Kubernetes
18. Introduction to Kubernetes 19. Deploying Our Microservices to Kubernetes 20. Implementing Kubernetes Features as an Alternative 21. Using a Service Mesh to Improve Observability and Management 22. Centralized Logging with the EFK Stack 23. Monitoring Microservices 24. Other Books You May Enjoy

Testing APIs manually

That concludes the implementation of our microservices. Let's try them out by performing the following steps:

  1. Build and start them up as background processes.
  2. Use curl to call the composite API.
  3. Stop them.

First, build and start-up each microservice as a background process, as follows:

cd $BOOK_HOME/Chapter03/2-basic-rest-services/

./gradlew build

Once the build completes, we can launch our microservices as background processes to the Terminal process with the following code:

java -jar microservices/product-composite-service/build/libs/*.jar &
java -jar microservices/product-service/build/libs/*.jar &
java -jar microservices/recommendation-service/build/libs/*.jar &
java -jar microservices/review-service/build/libs/*.jar &

A lot of log messages will be written to the Terminal, but after a few seconds, things will calm down and...

lock icon The rest of the chapter is locked
Register for a free Packt account to unlock a world of extra content!
A free Packt account unlocks extra newsletters, articles, discounted offers, and much more. Start advancing your knowledge today.
Unlock this book and the full library FREE for 7 days
Get unlimited access to 7000+ expert-authored eBooks and videos courses covering every tech area you can think of
Renews at $19.99/month. Cancel anytime