News for hackers. Stuff that matters.
Re:Chalice: Python Serverless Microframework for AWS by scrollaway on Monday July 11, 2016 @05:37PM (#12074900)
What makes you say Lambda is more expensive than things like EC2?

Obviously lambda is a hammer, not a swiss army knife - you shouldn't shoehorn it into your app just because it's the new tech on the block. But the use case isn't niche at all.

We're using lambda for our service to ingest and process Hearthstone replays. An HTTP POST is sent to the API gateway, this triggers a lambda which parses a 0.5-2MB file, scrapes the data in it and stores data in the db + converts it to another format. The whole process takes 3-6 seconds. Lambda lets us easily scale to dozens of requests per second without having to worry about anything other than the DB server. Our frontend/app servers don't need to be touched.

The alternative would be to provision and manage a lot of EC2 instances to handle the load. We'd have to worry about provisioning them dynamically so that it's economically viable. We'd have to manage the load balancing ourselves. Lambda's been a huge time saver.

PS: Let it be known that Lambda only supports python 2.7, not python 3, and that really frickin sucks. Get your shit together, Amazon.

Re:Chalice: Python Serverless Microframework for AWS by emjr on Monday July 11, 2016 @05:43PM (#12074954)
"Let it be known that Lambda only supports python 2.7, not python 3, and that really frickin sucks. Get your shit together, Amazon."

Node 4 support came, what, a month ago? It's pretty ridiculous.

Re:Chalice: Python Serverless Microframework for AWS by scrollaway on Monday July 11, 2016 @05:51PM (#12075012)
I specifically don't understand the Python 3 situation. They support Python 2, it can't be that complicated to have a separate Python 3 runtime.
Re:Chalice: Python Serverless Microframework for AWS by joobus on Monday July 11, 2016 @05:55PM (#12075042)
There is no significant benefit to python 3 over python 2.
Re:Chalice: Python Serverless Microframework for AWS by scrollaway on Monday July 11, 2016 @06:00PM (#12075103)
You're wrong, and it's irrelevant anyway. Our app is in Python 3. Having to support Python 2 just because lambda doesn't support 3.x is a pain.
Re:Chalice: Python Serverless Microframework for AWS by nameless912 on Monday July 11, 2016 @06:41PM (#12075376)
Unicode....?

I mean, that's reason enough. Python 2's string processing suuuuuuucks.

Re:Chalice: Python Serverless Microframework for AWS by brianwawok on Monday July 11, 2016 @06:00PM (#12075101)
Except that it is the way forward and many people choose to write python3 compatible code.
Re:Chalice: Python Serverless Microframework for AWS by timlyo on Tuesday July 12, 2016 @06:20AM (#12077915)
Re:Chalice: Python Serverless Microframework for AWS by SwellJoe on Monday July 11, 2016 @09:01PM (#12075998)
I've got (virtual) servers all over the place. I run my tiny little "needs a minute" tasks on one or more of those. It's nice, I guess to make it a wholly isolated thing, but I rarely actually want to go to the trouble to design it to be isolated. My little jobs often need at least some of the rest of my production environment to be available (database, logs, libs, something). Making a Lambda thing just for those things seems like something I'd rarely want to go to extra effort for.

But, if building on a very large scale with strict isolation requirements for your individual tasks it would make sense. Which is the niche I'm talking about; maybe it's just bigger than I assume it is.

Re:Chalice: Python Serverless Microframework for AWS by rckclmbr on Monday July 11, 2016 @06:29PM (#12075316)
Do you leave your database server publicly open (but password protected obviously), or can you use IAM policies for this as well?
Re:Chalice: Python Serverless Microframework for AWS by scrollaway on Monday July 11, 2016 @06:41PM (#12075378)
A quick google search of more 3-letter-acronyms than there are in the US government yields this:

- https://docs.aws.amazon.com/lambda/latest/dg/vpc-rds.html

- https://docs.aws.amazon.com/lambda/latest/dg/access-control-...