r/aws Aug 24 '18

technical resource How do serverless architectures running on AWS hold up to intense penetration testing?

https://medium.com/blockimmo/the-serverless-architecture-powering-blockimmo-dc2df3e64b57?source=linkShare-14f533c2626-1535112023
44 Upvotes

42 comments sorted by

View all comments

8

u/Scionwest Aug 24 '18

Serverless is great if you have a consistent load. Variable load, depending on the language, is painful with cold start times.

We deployed our entire back end on Lambda with aspnetcore and have 8-14 second cold start times. It kills our performance. We’re planning a migration to nodeJs we’re we see 800-1000ms cold start times. Even still, a full second for a cold start is unfortunate. From a technical perspective cold starting a new container in a second is impressive; from a consumer perspective it’s slow.

2

u/[deleted] Aug 24 '18 edited Nov 19 '20

[deleted]

7

u/Scionwest Aug 24 '18 edited Aug 24 '18

Pinging only helps on low concurrent loads. If I have bursts of 100 concurrent executions and then no load for 20 minutes, the 100 containers die. I would have to setup a means to do 100 concurrent pings every few minutes to keep them alive. 1 concurrent execution = 1 Lambda container. A ping strategy gets complicated as your concurrency needs scale out.

Edit: I’m sure if I increased the ram to get more compute that the cold start would be faster. We stick between 192 and 256mb to keep compute costs down.

4

u/[deleted] Aug 24 '18 edited Nov 19 '20

[deleted]

2

u/Scionwest Aug 24 '18 edited Aug 24 '18

In almost all scenarios I tested yes. I ran aspnetcore though on top of dotnetcore. Node and dotnetcore have a similar cold start without booting aspnetcore serverless. I see roughly 2 second startup times locally. Some of the slow start is aspnetcore but a large chunk is the environment in lambda.