I found it extremely frustrating in that what I expected/hope for was that I'd write a function that got called with some object that had the headers and body of an HTTP request to which I'd output a response.
Instead what I got was a (massively over engineered?) front end (the API Gateway) where the default is to add 10s or 100s of rules to try to have Amazon parse the request. As a JS dev I can only guess this was designed by Java programmers where strict typing might suggest such a convoluted solution?
It took a while to figure out how to turn off all that stuff and just pass the request to my lambda JS based function.
I feel like API Gateway should be doing absolutely nothing except routing requests to the appropriate service. That should be the default and all that parsing should be a separate service. In other words it should be
API Gateway (no parsing) -> lambda
and if you want parsing then you'd
API Gateway -> Parsing service -> lambda
Or for that mater just make the parsing a library you can use if you want.
OTOH I'm not a network person so maybe there's valid reasons for API Gateway to have such a giant configuration
Instead what I got was a (massively over engineered?) front end (the API Gateway) where the default is to add 10s or 100s of rules to try to have Amazon parse the request. As a JS dev I can only guess this was designed by Java programmers where strict typing might suggest such a convoluted solution?
It took a while to figure out how to turn off all that stuff and just pass the request to my lambda JS based function.
I feel like API Gateway should be doing absolutely nothing except routing requests to the appropriate service. That should be the default and all that parsing should be a separate service. In other words it should be
API Gateway (no parsing) -> lambda
and if you want parsing then you'd
API Gateway -> Parsing service -> lambda
Or for that mater just make the parsing a library you can use if you want.
OTOH I'm not a network person so maybe there's valid reasons for API Gateway to have such a giant configuration