When trying to use requests in my function, it only timeout without additional error. I was trying to use rapidapi for amazon. I already have the host and key, but when I test my function it always timeout. My zip file and my function were on the same directory and I knew that my code was correct.
1 Answer
I just figured out that my VPC configuration in Lambda was can only access within the resources of the VPC. I just removed the VPC and it now runs. But when your lambda function will connect to your database, you need to add and configure your VPC.
1 Comment
Sensei
No that's not quite true, you can utilize a Lambda function without a VPC but still utilize RDS just fine. The trick is you need to ensure that your RDS instance is accessible publicly. You can still use a SecurityGroup to filter out and drop other traffic safely on the RDS.