Closed JacobDel closed 1 year ago
If you have a database using serverless it can take a while to spin up the database. In this case you are likely to exceed the 30 apigateway timeout.
Is your lambda using other services that could cause a long request?
Yes, it has to retrieve the whole zip folder from S3 during bootup (because of slim_handler)
@JacobDel and @monkut lambda deployments are done using zip uploaded to S3. Either we're having a communication gap here or we can't understand @JacobDel's problem. @JacobDel let me know when can we sit on a call, I'm on available for next 3 days as I will be at home away from work.
Sorry for the delay on this issue. I won't have time to look deeper into it at the moment because of work. I will reopen this issue when I can find more time to see if it's a bug or not. My apologies
Context
Expected Behavior
I start up my application and call a couple of API calls simultaneously to the backend. The backend is already warm and thus is able to process the API calls immediately. The application received the API responses in time and no 503 errors occurred.
Actual Behavior
I get a 503 timeout error in my application when I make the first API call. When I try again then it works fine. From the tail logs from zappa I assume that the keep_warm_callback had no effect on the application and did not keep the lambda warm. These are the tial logs from zappa:
Possible Fix
/
Steps to Reproduce
Your Environment
pip freeze
:zappa_settings.yaml
:dev: app_function: "app.app" "aws_region": "eu-west-3" "profile_name": "project-name" "project_name": "project-name-backend" "s3_bucket": "project-bucket" cors: true "vpc_config": "SubnetIds":