[Microservices] An article to understand the Nginx gateway construction tutorial

Learn about the Nginx gateway building tutorial in one article

Nginx gateway construction

So what is Nginx?

nginx is a high-performance HTTP server, reverse proxy server, mail proxy server, TCP/UDP reverse proxy server.

A single system is mainly used to process client requests. The amount of client requests processed by a system is limited. When the client’s concurrency exceeds the system’s processing capacity, the performance of the server will be reduced and the speed will be slowed down, which will directly affect the user experience. , so in order to improve performance, we will create multiple service instances to form a cluster system to ensure high availability.

There are also some business scenarios that need to be exposed to third parties, so we need to expose some interfaces to third parties. At this time, we can use the reverse proxy of Nginx to proxy our back-end server. Users access our Nginx gateway, and then Nginx forwards it to our back-end business modules.
The detailed diagram is as follows:
insert image description here

nginx configuration

The premise is that Nginx has already been installed on our Linux, and the download process will not be demonstrated here.

http{
   
    
    
  server 

Guess you like

Origin blog.csdn.net/weixin_44427181/article/details/131308597