Elastic Container Service (ECS) vs Lambda Flashcards

1
Q

Amazon EC2 Container Service

A

Amazon ECS is a highly scalable, high performance container management service that supports Docker containers and allows you to easily run applications on a managed cluster of Amazon EC2 instances. ECS elminates the need for you to install, operate, and sclae your own cluster management infrastructure

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

With ECS, deploying containerized applications is easily accomplished. This service fits well in running batch jobs or in a microservice architecture

A

You have a central repo where you can upload your Docker images from ECS container for safekeeping called Amazon ECR

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

Applications in ECS can be written in a stateful or stateless matter

A

The Amazon ECS CLI supports Docker Compose, which allows you to simplify your local development experience as well as easily set up and run your containers on Amazon ECS

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

Since your applications still run on EC2 instances, server management is your responsibility. This gives you more granular control over your system

A

It is up to you to manage scaling and load balacing of your EC2 instances as well, unlike in AWS Lambda where functions scale automatically

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

You are charged for the costs incurred by your EC2 instances in your clusters. Most of the time, Amazon ECS most more than using AWS Lambda since your active EC2 instances will be charged hourly

A

One version of Amazon ECS, known as AWS Fargate, will fully manage your infrastructure so you can just focus on deploying containers. AWS Fargate has a different pricing model from the standard EC2 cluster

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

ECS will automatically recover unhealthy containers to ensure that you have the desired number of containers supporting your application

A
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

BREAK

A
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

AWS Lambda

A

AWS Lambda is a function as a service offering that runs your code in response to events and automatically manages the compute resources for you, since Lambda is a serverless compute service. With Lambda, you do not have to worry about managing servers, and directly focus on your application code

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

Lambda automatically scales your function to meet demands. It is noteworthy however that Lambda has a maximum execution duration per request of 900 seconds or 15 minutes

A

To allow your Lambda function to access other services such as CloudWatch Logs, you would need to create an execution role that has the necessary permissions to do so.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

You can easily integrate your function with different services such as API Gateway, DynamoDB, CloudFront etc using the Lambda Console

A

You can test your functiion code locally in the Lambda console before launching it into production

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
11
Q

Currently Lambda supports only a number of programming languages such as Java, Go, PowerShell, Node.js, C#, Python and Ruby. ECS is not limited by programming languages since it mainly caters to Docker

A

Lambda functions must be stateless since you do not have volumes for data storage

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
12
Q

You are charged based on the number of requests for your functions and the duration, the time it takes for your code to execute. To minimize costs, you can throttle the number of concurrent executions running at a time, and the execution time limit of the function

A

With Lambda@Edge, AWS Lambda can run your code across AWS Locations globally in response to Amazon CloudFront events, such as requests for content to or from origin servers and viewers. This makes it easier to deliver content to end users with low latency

How well did you know this?
1
Not at all
2
3
4
5
Perfectly