The Example with Kubernetes
In this lesson, we'll introduce an example with Kubernetes.
-
The catalog microservice manages the information about the items. It provides an HTML UI and a REST interface.
-
The customer microservice stores the customer data and also provides an HTML UI and a REST interface.
-
The order microservice can receive new orders. It provides an HTML UI and uses the REST interfaces of the catalog and customer microservice.
-
An Apache web server facilitates access to the individual microservices. It forwards the calls to the respective services.
The drawing above shows how the microservices interact. The order microservice communicates with the catalog and the customer microservice while the Apache httpd server communicates with all other microservices to display the HTML UIs.
The microservices are accessible from the outside via node ports. On each node in the cluster, a request to a specific port will be forwarded to the service. However, the port numbers are assigned by Kubernetes, so there is no port number in the figure.
A load balancer is set up by the Kubernetes service to distribute the load across Kubernetes nodes.
Implementing
...Get hands-on with 1400+ tech skills courses.