News for hackers. Stuff that matters.
Re:Google Cloud Spanner is now half the cost of Amazon DynamoDB by aketchum on Wednesday October 11, 2023 @02:25PM (#37848317)
yeah but you run into other issues when you put all of your lambdas on the same VPC
Re:Google Cloud Spanner is now half the cost of Amazon DynamoDB by nameless912 on Wednesday October 11, 2023 @02:28PM (#37848348)
Not to be that guy, but why lambdas? I'm genuinely curious. I've never found the "cost savings" (big air quotes) worth it in comparison to the increased configuration/permissions complexity. Especially when Fargate exists, where you can just throw a docker container at AWS, what do Lambdas add? The zero scaling?
Re:Google Cloud Spanner is now half the cost of Amazon DynamoDB by qvrjuec on Wednesday October 11, 2023 @02:35PM (#37848464)
With CDK, I can get an ECS service up and running in the same amount of time it'd take to create a lambda function behind API gateway or triggered by SQS/cron. Deploys are easier, cost savings are real, permissions/configuration are the same level of complexity unless you're cutting corners. I'd only use ECS for stuff I know would be high sustained throughput, long duration(>15m) tasks, or things that absolutely need more persistence between executions.
Re:Google Cloud Spanner is now half the cost of Amazon DynamoDB by hooverd on Wednesday October 11, 2023 @02:59PM (#37848799)
Serverless is great if you recognize that it's just somebody else's container runtime. I wish there was better tooling for Docker based Lambdas though. I hate whole S3 deployment dance for zip file based Lambdas (yes SAM does it for you now but it's still there).

EC2-backed ECS has a great use case for things that you can run ephemerally in a container but require a persistent data store.

Re:Google Cloud Spanner is now half the cost of Amazon DynamoDB by sakopov on Wednesday October 11, 2023 @02:34PM (#37848448)
Your mileage may vary, but I think in majority of the cases Fargate is going to be significantly more expensive than Lambda.
Re:Google Cloud Spanner is now half the cost of Amazon DynamoDB by nameless912 on Wednesday October 11, 2023 @02:53PM (#37848716)
But at low request volumes, either is a rounding error to a medium size enterprise, and for personal projects IMO Lambda is a huge PITA.
Re:Google Cloud Spanner is now half the cost of Amazon DynamoDB by meowtimemania on Wednesday October 11, 2023 @03:12PM (#37848944)
One of lambda's ideal use cases is personal projects. Personal projects usually serve very few requests so lambda's ability to scale to zero results in cost savings.
Re:Google Cloud Spanner is now half the cost of Amazon DynamoDB by hooverd on Wednesday October 11, 2023 @03:00PM (#37848812)
/shill The AWS SAM CLI smooths over a lot of Lambda's rough points. /unshill
Re:Google Cloud Spanner is now half the cost of Amazon DynamoDB by nameless912 on Wednesday October 11, 2023 @03:06PM (#37848879)
Gasp, a shill??

I totally believe you, I just can't see how it becomes easier than chucking a container on Fargate or something. Maybe I've just been scarred by lambda rat's nests in the past.

Re:Google Cloud Spanner is now half the cost of Amazon DynamoDB by hooverd on Wednesday October 11, 2023 @04:23PM (#37849795)
Yeah, the "proper" way to do Lambdas, shown in so many fancy architecture diagrams, is a rat's nest. I don't like APIs on Lambda unless you can shove them into one container with a catchall proxy on API Gateway. They really shine if you're processing SQS messages or EventBridge events. If you aren't using other AWS services and aren't cost engineering, then Lambdas probably aren't worth the headache.
Re:Google Cloud Spanner is now half the cost of Amazon DynamoDB by iends on Wednesday October 11, 2023 @04:32PM (#37849891)
The serverless framework makes lambda for side projects a breeze.

CDK for everything else.

Re:Google Cloud Spanner is now half the cost of Amazon DynamoDB by cdelsolar on Wednesday October 11, 2023 @03:59PM (#37849517)
I don't think that's actually true on a GB-second basis (memory * CPU)?
Re:Google Cloud Spanner is now half the cost of Amazon DynamoDB by hooverd on Wednesday October 11, 2023 @04:25PM (#37849828)
The cost efficiency of Lambda vs Fargate/EC2 ECS/one of the dozen other ways to run containers on AWS plummets as your RPS goes up.
Re:Google Cloud Spanner is now half the cost of Amazon DynamoDB by Olreich on Wednesday October 11, 2023 @04:27PM (#37849846)
Lambda is the most expensive thing you can do if you have more than 25% utilization. Fargate is extremely close to modern on-demand EC2 pricing (m7a family).
Re:Google Cloud Spanner is now half the cost of Amazon DynamoDB by makestuff on Wednesday October 11, 2023 @10:00PM (#37852656)
Yeah you can run Fargate on EC2 now as well to optimize cost even further.
Re:Google Cloud Spanner is now half the cost of Amazon DynamoDB by oarmstrong on Thursday October 12, 2023 @04:16AM (#37854694)
Fargate on EC2? Sorry you’ve lost me, I understood Fargate to be a layer of AWS managed compute for ECS or EKS deliberately instead of EC2.
Re:Google Cloud Spanner is now half the cost of Amazon DynamoDB by makestuff on Thursday October 12, 2023 @02:05PM (#37860692)
https://lumigo.io/blog/comparing-amazon-ecs-launch-types-ec2... You can now specify your launch type to be an ec2 instance. This has the benefit of lower cost but you are responsible for managing the instances ex: security patches, etc.
Re:Google Cloud Spanner is now half the cost of Amazon DynamoDB by oarmstrong on Saturday October 14, 2023 @03:51AM (#37878810)
Right, running ECS on EC2, not Fargate on EC2. When ECS launched it only had the EC2 launch type (where as you said you must manage your machines). Fargate then came along for both ECS and EKS where Amazon managed the machines for you.
Re:Google Cloud Spanner is now half the cost of Amazon DynamoDB by Zanfa on Wednesday October 11, 2023 @04:47PM (#37850043)
Why not? The setup I’m experimenting with for an API right now is basically a single Lambda that’s accessible through a function URL (so no ELB/ALB) + an RDS instance. Spinning up additional environments is a single Cloudformation call and deployment artifacts should work with both Docker containers or S3 (depending on the Lambda execution environment).

Seems like a leaner setup than using ECS/Fargate + LBs to me. Have I overlooked something?