Google Cloud Platform for Architects
上QQ阅读APP看书,第一时间看更新

Load balancing

The GCP offers several load-balancing options, all of which work with virtual machines. A common usage pattern is to use an HTTP/HTTPS-based load balancer (which deals with web traffic), and wire this up as a frontend, with several groups of VM instances at the backend.

Those groups could be managed instance groups (see following section), or just unrelated sets of instances. The load balancer will then distribute the incoming web requests to VMs in the backend.

This is a common way to distribute traffic based on user proximity (users from Asia should hit backend servers in Asia, those in Europe should hit backend instances in Europe), as well as content type (folks requesting hi-def video get directed to one set of instances, while those requesting regular video go to another).