diff --git a/hphp/runtime/server/fastcgi/fastcgi-session.cpp b/hphp/runtime/server/fastcgi/fastcgi-session.cpp index e45d8d76e9b49..9e451908a2c82 100644 --- a/hphp/runtime/server/fastcgi/fastcgi-session.cpp +++ b/hphp/runtime/server/fastcgi/fastcgi-session.cpp @@ -16,6 +16,7 @@ #include "hphp/runtime/server/fastcgi/fastcgi-session.h" #include "hphp/runtime/server/fastcgi/fastcgi-server.h" +#include "hphp/runtime/base/runtime-option.h" #include "hphp/util/logger.h" #include @@ -184,6 +185,10 @@ FastCGISession::FastCGISession( void FastCGISession::timeoutExpired() noexcept { // Hard shutdown; socket timed out + int timeout = RuntimeOption::ConnectionTimeoutSeconds; + // default 2 minutes FastCGIServer::FastCGIServer + if(timeout <= 0) timeout = 120; + Logger::Info("Fastcgi connection: connection time took longer than %d s and timeout, it will be shutdown!", timeout); dropConnection(); }