I am creating a Node.js based lambda function to query an AmazonRDS instance in the same VPC as the Lambda instance. The codebase uses npm libraries, so it needs to be zipped then updated via the console.
I wrote the code, zipped the files, and ran the following command :
aws lambda update-function-code --function-name (the arn of the function) --zip-file fileb://~/path/to/function/queryDatabase .zip
However, the console displays no output, and the function is not updated when it is viewed from the web interface.
This is my package.json
{
"dependencies": {
"aws-sdk": "^2.784.0",
"aws-xray-sdk-core": "2.4.0",
"aws-xray-sdk-mysql": "2.4.0",
"md5": "2.2.1",
"mysql2": "2.1.0"
}
}
How should I troubleshoot this issue? Thank you in advance!