Fargate minimum task set to one with load balancer

0

With AWS Fargate, can we have minimum task set to one with load balancer. If yes, will this able to provide HA(High Availability). ? Is this scenario behaves differently in ECS and EKS?

1 Risposta
0
Risposta accettata

With respect to ECS, you can always configure minimum task as 1 and i hope you have configured a service to monitor the state of the task as mentioned here: https://docs.aws.amazon.com/AmazonECS/latest/developerguide/create-service.html You can always integrate service to a load balancer and have your application running. Now if you ask me if this will provide HA, i would say no. The way it works is it tries to maintain the actual state is equal to desired state and the moment a task fails / gets terminated for some reason the service will monitor this and will create a new replica (maintaining the state). Now this will have a brief outage depending on the time taken for the task to enter running state. If you are thinking about HA, i would request you to start with a replica count greater than 1 and setup autoscaling policy based on Service's Average CPU, Memory and ALB request for high availability and better performance.

You will have similar experience with EKS as well where the service can be configured as Load balancer and can be run with 1 pod (equivalent to task in ECS). Best practice is to always make sure you run more than 1 replica and configure autoscaling using HPA /VPA for better performance. Refer to below link for EKS best practice :

https://learnk8s.io/production-best-practices#application-development

AWS
con risposta 4 anni fa

Accesso non effettuato. Accedi per postare una risposta.

Una buona risposta soddisfa chiaramente la domanda, fornisce un feedback costruttivo e incoraggia la crescita professionale del richiedente.

Linee guida per rispondere alle domande