com.google.gson.JsonSyntaxException: java.lang.IllegalStateException: Expected BEGIN_OBJECT but was STRING at line 1 column 1 path $

0

I am getting this error in my lambda function when i am calling my lambda without any parameter.

I am using java 11 as a runtime

已提问 10 个月前729 查看次数
1 回答
0

Hi,

This kind of error is not related to AWS Lambda but to the way that you use Google's Gson when you parse input data.

Have a look at this video to debug your code and solve: https://www.youtube.com/watch?v=k-F4Z7U7fpM

Best,

Didier

profile pictureAWS
专家
已回答 10 个月前

您未登录。 登录 发布回答。

一个好的回答可以清楚地解答问题和提供建设性反馈,并能促进提问者的职业发展。

回答问题的准则