hc-httpclient-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Philippe Mouawad <philippe.moua...@gmail.com>
Subject Re: HTTPClient 4 : Request hangs for 4-5 seconds when using IP's is used without reverse DNS only on Windows
Date Tue, 26 Aug 2014 19:47:00 GMT
Hello Oleg,
Getting back to this old thread which is cause of a JMeter issue:
https://issues.apache.org/bugzilla/show_bug.cgi?id=54449

I think it could be related to a JDK bug or feature:
http://bugs.java.com/bugdatabase/view_bug.do?bug_id=6450279

JDK7 has introduced a new method which could fix this issue:

   -
   http://download.java.net/jdk7/archive/b123/docs/api/java/net/InetSocketAddress.html#getHostString()


But it would make HTTPClient require Java 7 and JMeter also as a
consequence.

What's your opinion.

Regards
Philippe M.
@philmdot


On Tue, Feb 5, 2013 at 10:50 AM, Oleg Kalnichevski <olegk@apache.org> wrote:

> On Mon, 2013-02-04 at 22:25 +0100, Philippe Mouawad wrote:
> > Hello,
> >
> > We had an issue reported in JMerer related to HttpClient version 4.X.X
> > which does not happen in version 3.1.
> >
> > Thread dump shows thread hangs within InetAddress$1.getHostByAddr:
> >
> > "Thread Group 1-1" prio=6 tid=0x038f3c00 nid=0xd80 runnable [0x03b7f000]
> >    java.lang.Thread.State: RUNNABLE
> >         at java.net.Inet4AddressImpl.getHostByAddr(Native Method)
> >         at java.net.InetAddress$1.getHostByAddr(Unknown Source)
> >         at java.net.InetAddress.getHostFromNameService(Unknown Source)
> >         at java.net.InetAddress.getHostName(Unknown Source)
> >         at java.net.InetAddress.getHostName(Unknown Source)
> >         at sun.security.ssl.SSLSocketImpl.getHost(Unknown Source)
> >         - locked <0x1349be48> (a sun.security.ssl.SSLSocketImpl)
> >         at sun.security.ssl.Handshaker.getHostSE(Unknown Source)
> >         at sun.security.ssl.ClientHandshaker.getKickstartMessage(Unknown
> Source)
> >         at sun.security.ssl.Handshaker.kickstart(Unknown Source)
> >         at sun.security.ssl.SSLSocketImpl.kickstartHandshake(Unknown
> Source)
> >         - locked <0x1349be48> (a sun.security.ssl.SSLSocketImpl)
> >         at sun.security.ssl.SSLSocketImpl.performInitialHandshake(Unknown
> > Source)
> >         - locked <0x1349c038> (a java.lang.Object)
> >         at sun.security.ssl.SSLSocketImpl.startHandshake(Unknown Source)
> >         at sun.security.ssl.SSLSocketImpl.getSession(Unknown Source)
> >         at
> org.apache.http.conn.ssl.AbstractVerifier.verify(AbstractVerifier.java:91)
> >         at
> org.apache.http.conn.ssl.SSLSocketFactory.connectSocket(SSLSocketFactory.java:572)
> >         at
> org.apache.http.impl.conn.DefaultClientConnectionOperator.openConnection(DefaultClientConnectionOperator.java:180)
> >         at
> org.apache.http.impl.conn.ManagedClientConnectionImpl.open(ManagedClientConnectionImpl.java:294)
> >         at
> org.apache.http.impl.client.DefaultRequestDirector.tryConnect(DefaultRequestDirector.java:640)
> >         at
> org.apache.http.impl.client.DefaultRequestDirector.execute(DefaultRequestDirector.java:479)
> >         at
> org.apache.http.impl.client.AbstractHttpClient.execute(AbstractHttpClient.java:906)
> >         at
> org.apache.http.impl.client.AbstractHttpClient.execute(AbstractHttpClient.java:805)
> >         at
> org.apache.jmeter.protocol.http.sampler.HTTPHC4Impl.sample(HTTPHC4Impl.java:284)
> >         at
> org.apache.jmeter.protocol.http.sampler.HTTPSamplerProxy.sample(HTTPSamplerProxy.java:62)
> >         at
> org.apache.jmeter.protocol.http.sampler.HTTPSamplerBase.sample(HTTPSamplerBase.java:1075)
> >         at
> org.apache.jmeter.protocol.http.sampler.HTTPSamplerBase.sample(HTTPSamplerBase.java:1064)
> >         at
> org.apache.jmeter.threads.JMeterThread.process_sampler(JMeterThread.java:426)
> >         at
> org.apache.jmeter.threads.JMeterThread.run(JMeterThread.java:255)
> >         at java.lang.Thread.run(Unknown Source)
> >
> >
> >
> > Do you remember fixing this kind of issue within version 3.X ?, something
> > like this:
> > -
> http://www.velocityreviews.com/forums/showpost.php?p=2959030&postcount=8
> >
>
> Caching of resolved addresses also has downsides. For instance, it
> breaks simple load distribution schemes based on DNS round-robin.
>
> I am pretty certain HC 3.x does not use InetAddress caching. However, HC
> 4.x socket initialization logic is significantly different from that of
> 3.x.
>
> Oleg
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: httpclient-users-unsubscribe@hc.apache.org
> For additional commands, e-mail: httpclient-users-help@hc.apache.org
>
>


-- 
Cordialement.
Philippe Mouawad.

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message