News for hackers. Stuff that matters.
Re:AWS Lambda now supports up to 10 GB Ephemeral Storage by zozbot234 on Friday March 25, 2022 @09:42AM (#30802056)
If it's ephemeral to a function, it's not "storage". It's just core memory that may or may not be backed by physical "storage" media, and is organized as a tmpfs for the user's convenience.
Re:AWS Lambda now supports up to 10 GB Ephemeral Storage by 10000truths on Friday March 25, 2022 @10:41AM (#30802726)
One man’s swap-backed tmpfs is another man’s page-cache-backed filesystem. /s
Re:AWS Lambda now supports up to 10 GB Ephemeral Storage by DevKoala on Thursday March 24, 2022 @06:22PM (#30796117)
I remember when I was breaking my head against the wall to fit puppeteer inside a lambda. Good times.
Re:AWS Lambda now supports up to 10 GB Ephemeral Storage by otterley on Friday March 25, 2022 @11:01AM (#30802987)
What was the use case?
Re:AWS Lambda now supports up to 10 GB Ephemeral Storage by DevKoala on Friday March 25, 2022 @02:34PM (#30805612)
I was working for a programmatic advertising demand side platform. We had customers that submitted all sorts of ads to us and the lambda was in charge of rendering the ad and performing some validations on it. We accomplished it in the end using layers. It was in 2017, but it feels like a lifetime ago.
Re:AWS Lambda now supports up to 10 GB Ephemeral Storage by nunez on Thursday March 24, 2022 @11:21PM (#30798295)
this is fantastic for anyone wanting to run Chrome inside of Lambda (one of the biggest challenges is getting Chrome to fit)
Re:AWS Lambda now supports up to 10 GB Ephemeral Storage by matt-attack on Friday March 25, 2022 @02:20AM (#30799193)
What's the use case? I see a sibling commenter mentioned puppeteer which I'm aware is essentially Chrome. Are you too referring to running puppeteer in Lambda? If so, what is the purpose?
Re:AWS Lambda now supports up to 10 GB Ephemeral Storage by mulhoon on Friday March 25, 2022 @03:34AM (#30799548)
Puppeteer-core can already fit in a lambda around 60mb and can be used for web scraping, taking screenshots, or performance testing.
Re:AWS Lambda now supports up to 10 GB Ephemeral Storage by atonse on Friday March 25, 2022 @07:58AM (#30801041)
How’s the overhead? Are you launching full chrome every lambda invocation?
Re:AWS Lambda now supports up to 10 GB Ephemeral Storage by mulhoon on Friday March 25, 2022 @09:20AM (#30801796)
In one lambda I can load chrome, visit a website, take a screenshot and save it to S3 in around 2s with around 280mb memory used. You could keep chrome open and reuse it if available, but you can't count on it with lambda being stateless.

I use this Chromium binary https://www.npmjs.com/package/chrome-aws-lambda

Re:AWS Lambda now supports up to 10 GB Ephemeral Storage by vdm on Friday March 25, 2022 @10:49AM (#30802828)
> lambda being stateless

/tmp is ephemeral in the sense that it dies with the Lambda instance, but it is also persistent between multiple serial invocations landing on that instance, even if the instance is frozen and thawed between some of those invocations.

The process memory state on the instance (set up during the Init phase) is also available between invocations.

https://docs.aws.amazon.com/lambda/latest/dg/runtimes-contex...

Re:AWS Lambda now supports up to 10 GB Ephemeral Storage by zozbot234 on Friday March 25, 2022 @11:01AM (#30802990)
You can't count on that freezing and thawing process, it's not guaranteed at all. The whole point of Lambda/FaaS in general is that each invocation might be truly ephemeral, depending on factors that are largely beyond any single user's control.
Re:AWS Lambda now supports up to 10 GB Ephemeral Storage by nunez on Saturday March 26, 2022 @11:33AM (#30812735)
this package requires using JS for your stack. your options are much slimmer for other languages.
Re:AWS Lambda now supports up to 10 GB Ephemeral Storage by nunez on Saturday March 26, 2022 @11:33AM (#30812727)
Does that work outside of JS?
Re:AWS Lambda now supports up to 10 GB Ephemeral Storage by unixhero on Friday March 25, 2022 @03:50AM (#30799605)
Chrome headless
Re:AWS Lambda now supports up to 10 GB Ephemeral Storage by bl4ckm0r3 on Friday March 25, 2022 @09:16AM (#30801755)
scalable pdf rendering
Re:AWS Lambda now supports up to 10 GB Ephemeral Storage by giorgioz on Friday March 25, 2022 @02:19PM (#30805457)
This is also useful for deploying a big static website with AWS CDK which currently uses a Lambda and had the limit of 512mb (it was already possible to pass it by using an attached storage but this makes it easier).