FAAS architecture, how does lambda route requests?

When I make a REST call to my lambda endpoint, what happens? Does the call pass through ELB and then terminate right in my instance? Or is there another instance in the middle that terminates the http request and then converts the REST call to stdin - like Function Watchdog does with OpenFAAS?

Or is something like Function Watchdog running inside the wrapper AWS puts around my lambda code?
This is in reference to direct lambda invokes, not via API Gateway.

I guess I’m confused about how the TCP session from my client to AWS terminates when I’m making calls to different endpoints. Is there a session to each endpoint or is it shared somehow?

I’m wondering if lambda functions could be Docker images. The concept of Docker images as lambda functions is kind of neat since you can put bare binaries into a Docker image which are quite small. For example here is a Docker image that is 83KB in size.

https://spotinst.com/ is very close to this. They are pooling Docker images, and they are offering FASS. But they aren’t combining the two.

Why do this? To achieve lightweight functions with very fast response times. Functions in this model could potentially have latencies sub 10ms. All of my current lambdas are running in the 200ms+ range. Of course from a development prospective you’d start off with the current system and use Javascript or similar. This is for deploying high-volume, production code.

1 Like

If you want a deep understanding then you’ll need to find someone inside AWS who is willing to talk about it. From what I can tell the API GW terminates the HTTP endpoint and invokes the Lambda just like you could.

Not yet but I think it’s on the wish list for a lot of people.