

Review the following ways to troubleshoot a 504 error: This time limit is configured to avoid negatively affecting the network and overall performance of the CDN.Many times, the origin tries to redirect to itself or to the CDN, which can cause a redirect loop.īy default, the CDN will maintain a connection with an origin before the connection times out for 20 seconds.Use What's My DNS to view how your records are configured.ĬURL the origin URL to see where the redirect is going.Verify that your DNS records are properly configured and propagated. To learn more, see Review and Allowlist CDN / WAF IP Blocks.Verify that you have allowlisted StackPath IP blocks on your server's firewall. Some CMS security plug-ins may cause complications as a result, disable one plug-in at a time, and then refresh your site.Verify that DDoS protection settings have not been triggered by origin pull requests from the CDN.ĭisable CMS security plug-ins, and then refresh your site. Verify that your firewall does not drop requests from the CDN.


You can use this document to learn how to prevent and troubleshoot 502 and 504 errors that your users may see. These errors are commonly caused by either incorrect settings, origin server firewalls, origin server issues or connection timeouts. When integrated with the StackPath CDN, it's possible you may encounter 502 or 504 errors.

More details on setting up asynchronous invocation of the backend Lambda function can be found here – HTTP INTEGRATION If you are having a Lambda Integration for your API, asynchronously invoking lambda just needs X-Amz-Invocation-Type to be sent as value Event in Integration Request. At client end, You can implement a polling logic to call another API resource/method to check the status of task running in the backend. You can asynchronously Invoke your backend to return a HTTP 202 status code which means that the request has been accepted for processing, but the processing has not been completed. For HTTP APIs the Integration timeout limit is 30 seconds LAMBDA INTEGRATION As per the documentation, For Rest APIs 29 seconds Integration timeout limit is a hard limit which means it can’t be increased.
