5 ms·
AWS Lambda – Functions with Up to 10 GB of Memory and 6 VCPUs
- danpalmer 6y agoI think this is really neat. I've never really understood using Serverless platforms for websites and things that process web traffic as there's almost always enough that a "real" webserver is quicker, easier, and cheaper. However, I've seen many things that run a couple of times a day, or in response to a deployment, or things like that, which often need some compute behind them, but for which setting up a little server and hosting it somewhere just to call it once a day feels like so much unnecessary ceremony. Does this have a maximum function duration? If so this could still rule out this approach.
- munns 6y agoYes, you are still limited to 15 minute maximum duration. - Chris Munns - Lead of Dev Advocacy - Serverless@AWS
- danpalmer 6y agoOk that's not too bad a cap. I can see that working for quite a lot of use cases that aren't serving websites.
- spullara 6y agoGPUs please.
- panabee 6y agooracle plans to ship serverless GPUs in Q12021, according to our oracle rep. hope this means amazon and google are close as well.
- rainforest 6y agoIs there any potential for extending that limit? I work on a product that uses Fargate Spot as a kind-of lambda substitute to run longer-duration tasks consumed from SQS and being able to use lambda to do that would make life easier :)
- JoshTriplett 6y agoLikewise. Doesn't have to be indefinite; 1-2 hours would be wonderful.
- remify 6y agoFor a 1 hour process why not just launch an instance ? You can also probably use a spot instance to be even cheaper.
- JoshTriplett 6y agoInstances take longer to start up; Lambda processes requests in milliseconds or less. Lambda automatically manages a pool for you. If you're running a predictable process and you know how long it'll take in advance, an instance may make sense. If you're running an unpredictable process, where you won't know how long it'll take until it's done, and it might be quite fast, the low startup time and fine-granularity billing helps.
- bpodgursky 6y agoECS (potentially on Fargate) would be a reasonable stack for those tasks, given the 15 minute limit on Lambdas.
- WrtCdEvrydy 6y agoTo be honest, if it's a static site and you just need a little bit of compute... Cloudfront in front of S3 and lambda is probably the cheapest way to give someone a basic website (just a contact form and nothing else)
- Pfhreak 6y agoThis is my go to stack these days for personal projects. (That said, I'm a former AWS dev, so I'm super familiar with these moving parts.) It's easy to develop for, it's easy to automate deployments, I don't have to worry about keeping anything up to date, and I can just focus on the small amount of code I want to write. The most expensive thing is the Route 53 configuration at $0.50/month/domain.
- madoublet 6y agoI love this stack. I recently added AWS SAM to the mix as well so that I can automate deployments. I have always wondered why Route 53 was so expensive relative to the other services. I have a collection of low traffic sites that I run for local businesses and this is always the most expensive part. I guess it's hard to complain about $0.50. But, given I could probably run them all on $5 DO droplet, it ends up costing a little more.
- vagab0nd 6y agoIt's my goto stack as well. However, I haven't been able to get both www->root redirect and http->https redirect working. Do you happen to know if it's possible?
- klohto 6y agowww->root should be handled on DNS, therefore Route53. http->https can be done using CloudFront and Lambda@Edge
- ignoramous 6y agofly.io (upto 8CPUs + 8GiB) and stackpath.com (upto 8CPUs + 32GB) both can run such workloads at the Edge. That said, AWS Fargate and AWS Batch (minus the Edge) are probably comparable services to those than AWS Lambda. [0] https://fly.io/docs/about/pricing/ https://fly.io/docs/about/pricing/ [1] https://www.stackpath.com/products/containers/ https://www.stackpath.com/products/containers/
- austinpena 6y agoAre you familiar with stackpath? Does anyone have words to share about them?
- ignoramous 6y agoStackPath is kind of edge-essential services from Cloudflare and AWS rolled into one. I used StackPath's Serverless functions once before and they worked as advertised (but since moved to Cloudflare Workers).
- austinpena 6y agoThanks for the response. I’m currently using them and liking them. Not as sexy as CF workers but I can have 100 delivery domains per site so my customers can point at me for essentially free.
- pwinnski 6y agoWow, other people clearly use lambdas for far different purposes than I do!
- nuclid 6y agoWell we run some ML & OCR workloads on Lambda. Zip file size limit has always been a big problem since we need to package a lot of dependencies. Also 3GB of RAM is way too low for some image processing tasks. This is a huge improvement for us.
- igorsusmelj 6y agoI'm still afraid of the latency to setup the environment before executing my function. With python and several pip dependencies, it always takes some time...
- symlinkk 6y agoDidn’t they announce that you can use containers with lambdas now? So just put your environment in a container
- yandie 6y agoLambda still needs to load your container. So there's gonna be slow start cost (but hopefully they can improve caching overtime)
- igorsusmelj 6y agoLike Google Cloud Run?
- sciurus 6y agoDid they? I can't find that from a quick Google search. Edit: They announced it today; see https://aws.amazon.com/blogs/aws/new-for-aws-lambda-container-image-support/ https://aws.amazon.com/blogs/aws/new-for-aws-lambda-containe...
- wongarsu 6y agoEven though it's often sold that way, I don't think Lambda is a good fit for interactive use cases. Unless it's used sparingly you don't really want it serving your website or api. It's much better suited for glue code, cron jobs, processing some work queue, etc.
- martindbp 6y agoCurious: would you need a work queue with auto-scaling lambdas?
- freeqaz 6y ago
- martindbp 6y agoIs it a bad idea to use AWS Lambda to serve ML models? If cold-start latency is not much of an issue.
- freeqaz 6y agoIt depends. Do you need a GPU? If so, your options are more limited. If not, then it's definitely doable!
- komuher 6y agoNo GPU so ye its very bad :P
- yandie 6y agoDepends on whether you need GPU for model serving. Most companies I talk to use CPU for serving and GPU for training, so it's not a bad idea
- dcu 6y agoWe use it for inference and it works fine. Now with EFS support it's even better. We have used it successfully with both Tensorflow and Gorgonia
- bmcahren 6y agoDid they ever raise the lambda image size? We'd have to chop our app up and that would introduce too much risk but we are suddenly capable of migrating the core to lambda with 6GB+ of RAM needed for our ETL. Image sizes were really small and we'd have to bundle in Puppeteer and other large libs so it's tough to build a bundle that fits on lambda.
- aeyes 6y agoThey just announced that you can use Docker images in Lambda of up to 10GB in size, that should solve all of these problems: https://aws.amazon.com/blogs/aws/new-for-aws-lambda-container-image-support/ https://aws.amazon.com/blogs/aws/new-for-aws-lambda-containe...
- emilsedgh 6y agoI wonder what are the advantages of Lamdba comparing to a serverless container solution like Google Cloud Run. Anyone with expertise likes to chime in?
- dennisy 6y agoI love lamp(da)