gpt4 book ai didi

php - 连接 Facebook Graph API 时 ElasticBeanstalk for PHP 上的 504 网关超时

转载 作者:可可西里 更新时间:2023-10-31 23:40:27 26 4
gpt4 key购买 nike

当用户使用他们的 Facebook 登录名连接到我的网络应用程序时,服务器不会重定向回来,因为它在途中捕获了 504 错误。

它在我的本地测试环境中正常工作,但在我使用 Amazon Elastic Beanstalk 作为平台的暂存服务器上出现问题。

知道如何解决这个问题吗?

最佳答案

来自 http://docs.aws.amazon.com/ElasticLoadBalancing/latest/DeveloperGuide/ts-elb-error-message.html

Description: Indicates that the load balancer closed a connection because a request did not complete within the idle timeout period.

Cause 1: The application takes longer to respond than the configured idle timeout.

Solution 1: Monitor the HTTPCode_ELB_5XX and Latency CloudWatch metrics. If there is an increase in these metrics, it could be due to the application not responding within the idle timeout period. For details about the requests that are timing out, enable access logs on the load balancer and review the 504 response codes in the logs that are generated by Elastic Load Balancing. If necessary, you can increase your back-end capacity or increase the configured idle timeout so that lengthy operations (such as uploading a large file) can complete.

Cause 2: Registered instances closing the connection to Elastic Load Balancing.

Solution 2: Enable keep-alive settings on your EC2 instances and set the keep-alive timeout to greater than or equal to the idle timeout settings of your load balancer.

关于php - 连接 Facebook Graph API 时 ElasticBeanstalk for PHP 上的 504 网关超时,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/24547861/

26 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com