Internal Server Error from API Gateway when sending queries through gateway to Lambda function connected to RDS database

0

I have an S3 website that is connected to a database through an API Gateway and a Lambda function. The API Gateway receives SQL queries as text and passes them to the Lambda function. The Lambda function runs those queries against the database and returns the query results to the API Gateway. The API Gateway then sends the results back to S3. This usually works fine, except whenever I use an Insert statement with multiple values. Whenever I try to insert multiple rows into the table at the same time, I get an internal server error with code 500. How can I avoid this?

2개 답변
0

Maybe your function times out? Check the function logs to find out if it failed or not. If all OK in the function, enable execution logs in API Gateway and check why it reports a failure.

profile pictureAWS
전문가
Uri
답변함 2년 전
0

In addition to Uri - review the following url which does have some good tips to resolving the issue
https://aws.amazon.com/premiumsupport/knowledge-center/http-5xx-errors-s3/

답변함 2년 전

로그인하지 않았습니다. 로그인해야 답변을 게시할 수 있습니다.

좋은 답변은 질문에 명확하게 답하고 건설적인 피드백을 제공하며 질문자의 전문적인 성장을 장려합니다.

질문 답변하기에 대한 가이드라인

관련 콘텐츠