From: Eric Covener Date: Mon, 24 Jun 2013 20:40:05 +0000 (+0000) Subject: re-try LDAP connections in a few authz paths. X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=3bcea5fa6d1362667230652f66e3664a6c825b2f;p=thirdparty%2Fapache%2Fhttpd.git re-try LDAP connections in a few authz paths. git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1496207 13f79535-47bb-0310-9956-ffa450edef68 --- diff --git a/CHANGES b/CHANGES index 3c814e6a43a..0aacf155c55 100644 --- a/CHANGES +++ b/CHANGES @@ -1,6 +1,10 @@ -*- coding: utf-8 -*- Changes with Apache 2.5.0 + *) mod_ldap: Retry transient LDAP connection errors when they occur + during the authorization stage. + [Eric Covener] + *) mod_ldap: Don't keep retrying if a new LDAP connection times out. [Eric Covener] diff --git a/modules/ldap/util_ldap.c b/modules/ldap/util_ldap.c index 9326add09a0..da0db6ea142 100644 --- a/modules/ldap/util_ldap.c +++ b/modules/ldap/util_ldap.c @@ -1113,7 +1113,11 @@ start_over: } if (LDAP_SUCCESS != (result = uldap_connection_open(r, ldc))) { - /* connect failed */ + if (AP_LDAP_IS_SERVER_DOWN(result)) { + failures++; + goto start_over; + } + /* something other than 'server down' */ return result; } @@ -1230,7 +1234,11 @@ start_over: if (LDAP_SUCCESS != (result = uldap_connection_open(r, ldc))) { - /* connect failed */ + failures++; + if (AP_LDAP_IS_SERVER_DOWN(result)) { + goto start_over; + } + /* something other than 'server down' */ return res; }