edit-icon download-icon

Overview

Last Updated: Jan 11, 2018

Service discovery and Server Load Balancer mainly solves the issue of communication reliability. To guarantee the reliability, Container Service introduces the Server Load Balancer mechanism. Communication is divided into two types: communication that exposes services and communication between internal services. See the following scenarios for different solutions.

Scenario 1

We recommend that you use simple routing service for simple Layer-7 protocol Server Load Balancer and web service reverse proxy. For more information, see Simple routing - supports HTTP and HTTPS, Simple routing - configure domain names, and Simple routing - change HTTP to HTTPS.

Scenario 2

Server Load Balancer distributes the loads evenly to containers with the same functions in Layer-4 protocol Server Load Balancer and services of non-container clusters access the services of containers in container clusters when a traditional architecture is migrated to a container architecture. We recommend that you use Server Load Balancer routing.

Scenario 3

Services in the same cluster need to discover and communicate with each other, and need the Server Load Balancer capabilities. We recommend that you use Routing and Server Load Balancer between services in a cluster.

Scenario 4

Services in the same cluster need to discover and communicate with each other, but do not need the Server Load Balancer capabilities. We recommend that you use Service discovery between containers.

Scenario 5

Server Load Balancer and service discovery have high customization requirements, such as the support for extensive domain names, custom error page, record accessing logs, selection of backend services based on URL parameter values, and custom HAProxy configuration files. We recommend that you use custom routing. For more information, see Custom routing - user guide and Custom routing - simple sample.

Thank you! We've received your feedback.