HTTPCLIENT-1462: include source port, host information in the debug level output
git-svn-id: https://svn.apache.org/repos/asf/httpcomponents/httpclient/trunk@1569325 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
08f88336a1
commit
22d2c89b55
|
@ -42,7 +42,6 @@ import org.apache.http.config.Lookup;
|
|||
import org.apache.http.config.SocketConfig;
|
||||
import org.apache.http.conn.ConnectTimeoutException;
|
||||
import org.apache.http.conn.DnsResolver;
|
||||
import org.apache.http.conn.HttpClientConnectionManager;
|
||||
import org.apache.http.conn.HttpClientConnectionOperator;
|
||||
import org.apache.http.conn.HttpHostConnectException;
|
||||
import org.apache.http.conn.ManagedHttpClientConnection;
|
||||
|
@ -65,7 +64,7 @@ public class DefaultHttpClientConnectionOperator implements HttpClientConnection
|
|||
|
||||
static final String SOCKET_FACTORY_REGISTRY = "http.socket-factory-registry";
|
||||
|
||||
private final Log log = LogFactory.getLog(HttpClientConnectionManager.class);
|
||||
private final Log log = LogFactory.getLog(getClass());
|
||||
|
||||
private final Lookup<ConnectionSocketFactory> socketFactoryRegistry;
|
||||
private final SchemePortResolver schemePortResolver;
|
||||
|
@ -133,6 +132,9 @@ public class DefaultHttpClientConnectionOperator implements HttpClientConnection
|
|||
sock.setSoLinger(linger > 0, linger);
|
||||
}
|
||||
conn.bind(sock);
|
||||
if (this.log.isDebugEnabled()) {
|
||||
this.log.debug("Connection established " + conn);
|
||||
}
|
||||
return;
|
||||
} catch (final SocketTimeoutException ex) {
|
||||
if (last) {
|
||||
|
|
Loading…
Reference in New Issue