Posted On: Aug 11, 2016

Amazon EC2 Container Service (ECS) now supports the Application Load Balancer for the Elastic Load Balancing (ELB) service.

The Application Load Balancer offers you a high-performance load balancing option that operates at the application layer and allows you to define routing rules based on content. The Application Load Balancer also offers service-level monitoring and visibility to monitor the health of each service and integrates with other popular AWS services including AWS Certificate Manager, and Amazon API Gateway. This enables applications to be built both quickly at scale and optimized by grouping them as independent services. The Application Load Balancer makes it easier to run multiple applications on an ECS cluster.

Previously, you had to define a fixed host port for your container to use ELB to route traffic to your applications, preventing multiple copies of the same task from running on the same host. There was also a one-to-one mapping between ECS services and ELBs, increasing the complexity of running microservices applications. 

Now, you can specify a dynamic host port which gives your container an unused port when it is scheduled on an EC2 instance. The ECS scheduler will automatically add the task to the Application Load Balancer using this port. An ELB can also be shared amongst multiple services using path-based routing. Each service can define its own URI, and that URI routes traffic to that service. In addition, you can create an environment variable with the service’s ELB DNS name, supporting service discovery. 

Read more about the integration between Amazon ECS and the Application Load Balancer on the AWS Blog and in the Amazon ECS documentation. Please visit our product page for more information about Amazon EC2 Container Service.

ECS-ny