Fargate pricing confusion

0

Hi Guys, I am having hard time to understand Fargate pricing. So the example here is telling me if my tasks run 10 minutes a day for 30 days.. Why giving me 10 minutes? If I create 4 different micro services each at least 2 instance=8 and all of them wll be running whole day. My confusion is running 10 mins idea. Are you saying you should run your services 10 minutes, and sometimes stop or am I missing. This 10 minutes example does not make sense. If I put my MS definitely they will run 24 hourX30 day. If documentation is giving me 10 minutes example , I feel like I am missing something here. Last example is giving 1 hour example =$47, if I keep all my services run 24 hours the cost will be really high, compare to manually creating = ALB+EC2 For example in Lambda the price is about execution time. in case of Fargate what is if "running" 10 mins mean,

Thanks https://aws.amazon.com/fargate/pricing/

ozy
asked a year ago399 views
1 Answer
1
Accepted Answer

Yes so AWS Fargate is a serverless compute option in that you only worry about running your Task (container) so the billing is based on number of task plus vCPU and Memory per second used. This is because AWS is taking on the undifferentiated heavy lifting of managing the provision, configuration or scale of the nodes your task run on, as well no longer need to optimize your cluster, so thus cost associated with it. As well the security benefits of running on Fargate (isolation boundaries).

Also with ECS you have the scheduler which allows you to run tasks as always on or schedule them or kick them off through your own processes or operator [1], if they dont need to run all the time and save money. The best way to look at pricing is to the use the calculator to get a good idea of cost [2].

AWS Fargate is serverless but you need to determine if the cost of operating your own is worth the money saved for your compute.

[1]https://docs.aws.amazon.com/AmazonECS/latest/developerguide/scheduling_tasks.html [2]https://calculator.aws/#/addService/Fargate

AWS
answered a year ago
  • Hi Aaron, Seems like I am completely on wrong path by choosing Fargate. Because my microservices are not small task that I can stop sometimes and run sometimes, it is logistic and commerce app that has multiple functionality in it, it has membership, shipment, delivery, payment and reporting features. Instead if keeping all features in one monolithic app, I divided them in separate MS.

    So there is no time that these MS will stop or they can run as small tasks sometimes. I was trying to choose between Kubernates and Fargate, none of docs told me that Fargate is only for a tasks that can run sometime. In my case I am trying to run many apps that must be up all the time. Now I am thinking the cost is going to be too high. What will be other better deployment option? Thank you

  • Hi Ozy, With any design there are trade offs, Fargate can still work for a complete MS application but it will cost more because you are allowing AWS to do the heavy lifting for you (isolation, manage the cluster(scaling), manage the OS etc) so if those are things you dont want to do Fargate would be a good choice but with higher cost. If you prefer to roll it your own and try to save operational cost then you could simply run your MS on EC2 instance with ECS, you till take on some of the operational up keep but it still easier to manage then EKS(unless you have alot of experience or need more advanced features). Also you could do a mix here, for a service in your cluster you want that more secure boundary or some of the heavy operational lift removed from you, you could run on Fargate and then the rest on EC2.

    As well I would like to point out since these sounds like steady workloads (for most part) you can use Saving Plans to agree to a certain term of spend on your Compute and AWS will give you a discount, this can be used with either EC2 or Fargate instances.

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