3 ms·
This is making me wonder whether we should be paying for GC or just having Lambda abandon workers whose heaps are full and spin up more.
by prodigal_erik 10y ago
This is making me wonder whether we should be paying for GC or just having Lambda abandon workers whose heaps are full and spin up more.
- mrmagooey 10y agoI wouldn't have thought the GC would be expensive enough to warrant turning it off, interesting thought though.
- pmontra 10y agoLambda doesn't destroy the instance at the end of the response. It keeps it running just in case other requests arrive. If that happens you might want GC or a worker eventually runs out of memory. What could happen with Lambda and similar services is that costs will take back under the spotlight "old" languages that run with little memory and little CPU cicles. I'm even thinking about C. I'm not into Go, but that looks like another candidate. Scenarios: those ubiquitous web services running on a single VM because it's more than enough. The customer has to pay for it all the time and could save money if the app can run on Lambda. Enough to pay more in developer time?
- jimpick 10y agoWhat surprised me with Lambda is that it 'freezes' the VM your code is running in, and 'unfreezes' it when more requests come in. Very clever - they can store a lot of frozen VMs on an SSD. It surprised me when I discovered that a cache I had written in my code was already populated! I think most code running on lambda is not going to be CPU bound. In lambda-comments case it's mostly going to be idling as it waits for TCP/IP traffic to/from Akismet, S3, DynamoDB, Slack notification webhooks, etc.