Using infrastructure support
Ideally, you want to design and implement your APIs so they can work well without depending on a specific infrastructure setup. However, software developers should be aware that components external to the services they develop can be used to enhance the performance and scalability of the system.
There are several types of infrastructure components:
- Load balancer: A component distributes the requests among multiple service instances providing the same API. A load balancer is inevitable for horizontal scaling.
- Proxy: A component that is an HTTP server and client at the same time. It receives a request and fulfills it by making another request to the actual service providing the API. Proxies let us add various functionalities between the client and the server, of which caching is the most important one for performance:
- A proxy that receives requests with public URLs and turns them into requests within a private network is called...