By using AWS re:Post, you agree to the AWS re:Post Terms of Use

About AWS Fargate

0

I am new to AWS Fargate

For the situation, I run Trino in EKS workloads with 1 worker 1 node 24 hours a day using 2 core CPU and min 4GB to max 6GB of memory in EC2 instance. So when I bring my Trino setup in AWS Fargate:

Question 1: How does Trino scale up, scale down, scale in & scale out?

Question 2: when my workloads uses more memory from normally 4GB to its peak of 6GB, how long does Fargate take action and complete provide resources for my workloads?

Question 3: Same situation of question 2, when scaling, does my workloads stop or pause for a while in order to let Fargate complete its scaling job or my workloads still work normal from the beginning to the end of the scaling? Additionally, does the answer for scale up applied to scale down too or it is different?

Question 4: About the pricing is based on vCPU and memory:

CPU Memory Values 0.25 vCPU 0.5 GB, 1 GB, and 2 GB 0.5 vCPU Min. 1 GB and Max. 4 GB, in 1 GB increments 1 vCPU Min. 2 GB and Max. 8 GB, in 1 GB increments 2 vCPU Min. 4 GB and Max. 16 GB

based on my Trino workloads uses from 4gb to 6gb, so which configuration does Fargate use? And how many CPU does 1 vCPU equal to ? Does vCPU matter to the performance of my workloads?

1 Answer
0

AWS Fargate is a serverless compute engine for containers that works with Amazon EKS and ECS. Let me address your questions about running Trino on Fargate:

  1. Scaling in Fargate: Fargate doesn't automatically scale your Trino workload. You would need to set up auto-scaling policies for your EKS cluster using Kubernetes Horizontal Pod Autoscaler (HPA) or Cluster Autoscaler. These can scale based on metrics like CPU utilization or custom metrics.

  2. Resource allocation time: Fargate typically provisions resources very quickly, usually within 30 seconds to a minute. When your workload needs more memory (from 4GB to 6GB), Fargate will allocate the resources almost immediately once the scaling decision is made by your auto-scaling policies.

  3. Scaling impact on workloads: During scaling, your existing Trino workload continues to run without interruption. Fargate adds or removes tasks/pods as needed, but doesn't affect running containers. This applies to both scaling up and down. Your workload remains operational throughout the process.

  4. Pricing and configuration: For your Trino workload using 4-6GB of memory, Fargate would use the 2 vCPU configuration with 4-16GB memory range. You'd be charged for the actual memory used (4-6GB) and 2 vCPUs.

Regarding vCPU, 1 vCPU is generally equivalent to 1 CPU core. vCPU does matter for performance - more vCPUs mean more processing power for your Trino workload. However, the optimal configuration depends on your specific workload characteristics and performance requirements.

Remember, Fargate charges per second with a one-minute minimum for the resources you allocate to your tasks. You're billed for the larger of either the amount of CPU or memory you request.

When migrating from EC2 to Fargate, you'll need to adjust your deployment and scaling strategies to leverage Fargate's serverless model effectively.

Sources
AWS Fargate for Amazon ECS - Amazon Elastic Container Service
Serverless Compute Engine–AWS Fargate Pricing–Amazon Web Services
When to use Fargate - AWS Batch

profile picture
answered a month ago

You are not logged in. Log in to post an answer.

A good answer clearly answers the question and provides constructive feedback and encourages professional growth in the question asker.

Guidelines for Answering Questions