Proxies

System Design

Proxies

Reversed Proxy Server

Reversed Proxy Server

Reversed Proxy Server

On the other hand, a reverse proxy sits in front of one or more servers, intercepting the requests made by the clients. The proxy will then forward the request to the destination server and receives responses. The clients think it is directly communicating with the destination server. The proxy in this case resides on the server side and makes sure that no client interacts with the origin server directly.

Benefits of a reverse proxy server

  1. Load Balancing - Reverse proxies can be used as a load balancer to distribute incoming web traffic to multiple web servers.

  2. Caching - Reverse Proxy server may cache data which reduces response time to the user, improving the performance of a system.

  3. Improved Security - Proxy servers offer protection from DDos attacks. A DDos attack is used to exponentially increase requests to the servers in order to overwhelm them and bring the services down. An example is the attack on GitHub which was bombarded by requests 126.9 million requests per second. Within 10 minutes, GitHub sounded an alarm and routed the traffic to its DDoS mitigation service which sorted and blocked the malicious traffic. Proxies can be used to protect the servers from DDos by detecting whether a spike in traffic is legitimate or not, offering a traffic scrubbing effect.

  4. SSL termination - The proxy can handle any incoming HTTPS connections, decrypting the requests and passing the unencrypted requests onto the web servers. This eliminates the need to install SSL certificates in different back-end web servers by providing a single point of configuration. It also takes the processing load of encryption and decryption away from the web servers.

  5. Logging and Auditing - Proxies makes an excellent point of logging and auditing because all the HTTP requests are routed by the proxy.

Disadvantages of a reverse proxy server

  1. Increased Complexity - Adding proxies to the architecture increases system complexity.

  2. Single Point of Failure - A single proxy can introduce a point of failure and the addition of multiple proxies will complicate the system further.

Whenever you're ready

There are 4 ways we can help you become a great backend engineer:

The MB Platform

Join 1000+ backend engineers learning backend engineering. Build real-world backend projects, learn from expert-vetted courses and roadmaps, track your learnings and set schedules, and solve backend engineering tasks, exercises, and challenges.

The MB Academy

The “MB Academy” is a 6-month intensive Advanced Backend Engineering BootCamp to produce great backend engineers.

Join Backend Weekly

If you like post like this, you will absolutely enjoy our exclusive weekly newsletter, Sharing exclusive backend engineering resources to help you become a great Backend Engineer.

Get Backend Jobs

Find over 2,000+ Tailored International Remote Backend Jobs or Reach 50,000+ backend engineers on the #1 Backend Engineering Job Board