I get this error when running my AWS Lambda No response from invoke container for Function
. I would expect it to return the "hello world" String that I defined as output:
I also tried it with this simplier Lambda function, but I get the same error:
public class App implements RequestHandler<String, String> {
public String handleRequest(final String input, final Context context) {
return "H";
}
}
I started Docker locally to run this Lambda with the Docker Quickstart Terminal:
Do I maybe need to do anything else in Docker?
This is how I created the new AWS Lambda project with the IntelliJ Plugin AWS Toolkit:
- File -> New Project:
and selected following settings:
- The created project had a lot of errors, (Cannot resolve symbol 'String' etc.). I was able to resolve the errors by deleting the .idea folder, then click on File ->
Invalidate Caches and Restart
:
Then the project loads properly, but I don't get that Lambda symbol next to my App class:
- So I go to pom.xml, right click and then
Import as Maven project
. This works and I see the Lambda symbol now:
But I get a new Error in the AppTest class, and when I try to run it, it says can't find the app handler.
5. I resolved this by changing APIGatewayProxyRequestEvent
in the RequestHandler
to 'Object':