Bug 57319 - Upgrade to HttpClient 4.5.2
Summary: Upgrade to HttpClient 4.5.2
Status: RESOLVED FIXED
Alias: None
Product: JMeter - Now in Github
Classification: Unclassified
Component: HTTP (show other bugs)
Version: 2.13
Hardware: All All
: P2 enhancement with 2 votes (vote)
Target Milestone: ---
Assignee: JMeter issues mailing list
URL:
Keywords:
Depends on:
Blocks: 58583 58881
  Show dependency tree
 
Reported: 2014-12-06 15:18 UTC by Philippe Mouawad
Modified: 2016-02-26 22:53 UTC (History)
1 user (show)



Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Philippe Mouawad 2014-12-06 15:18:15 UTC
We need to upgrade to more recent HttpClient as it has interesting improvements made for JMeter.

@sebb you mentionned you had started working on this, maybe submitting a patch of current state or commit partial work would be interesting to complete work.
Comment 1 William L 2015-06-12 05:24:33 UTC
+1 for this.

Related to #57935
Comment 2 Philippe Mouawad 2015-12-20 14:43:11 UTC
Author: pmouawad
Date: Sun Dec 20 14:41:30 2015
New Revision: 1721032

URL: http://svn.apache.org/viewvc?rev=1721032&view=rev
Log:
Bug 57319 - Upgrade to HttpClient 4.5.X
Bugzilla Id: 57319

Modified:
    jmeter/trunk/build.properties
    jmeter/trunk/eclipse.classpath
    jmeter/trunk/licenses/bin/README.txt
    jmeter/trunk/res/maven/ApacheJMeter_parent.pom
    jmeter/trunk/src/protocol/http/org/apache/jmeter/protocol/http/control/CookieManager.java
    jmeter/trunk/src/protocol/http/org/apache/jmeter/protocol/http/control/HC4CookieHandler.java
    jmeter/trunk/src/protocol/http/org/apache/jmeter/protocol/http/sampler/MeasuringConnectionManager.java
    jmeter/trunk/test/src/org/apache/jmeter/protocol/http/control/TestCookieManager.java
    jmeter/trunk/xdocs/changes.xml
Comment 3 Philippe Mouawad 2015-12-20 16:28:26 UTC
Author: pmouawad
Date: Sun Dec 20 16:27:27 2015
New Revision: 1721042

URL: http://svn.apache.org/viewvc?rev=1721042&view=rev
Log:
Bug 57319 - Upgrade to HttpClient 4.5.X
Document why there cannot be any issue due to case difference on IGNORE_POLICY between HC3 and HC4
Bugzilla Id: 57319

Modified:
    jmeter/trunk/src/protocol/http/org/apache/jmeter/protocol/http/control/HC4CookieHandler.java
Comment 4 Sebb 2016-01-05 22:46:17 UTC
There are lots of deprecation warnings still to fix.
Comment 5 Philippe Mouawad 2016-01-06 12:23:15 UTC
(In reply to Sebb from comment #4)
> There are lots of deprecation warnings still to fix.

As discussed on mailing list, I had created Bug 58757 to follow fix of deprecated methods.

If you want this bug to stay Open , then I suggest you close the other one.
But it should be publicly mentionned that HttpClient was upgraded
Comment 6 Philippe Mouawad 2016-01-09 20:42:10 UTC
Author: pmouawad
Date: Sat Jan  9 20:41:41 2016
New Revision: 1723881

URL: http://svn.apache.org/viewvc?rev=1723881&view=rev
Log:
Bug 57319 - Upgrade to HttpClient 4.5.X
Replace deprecated methods
Bugzilla Id: 57319

Modified:
    jmeter/trunk/src/protocol/http/org/apache/jmeter/protocol/http/control/CacheManager.java
Comment 7 Gordon McKinney 2016-02-02 00:01:36 UTC
*** NOTE ***
Even with these changes SSL SNI is not supported. You need to make the following two changes and then server_name / SNI / Subject-Alternative-Naming works.

FILE: ./src/protocol/http/org/apache/jmeter/protocol/http/util/HC4TrustAllSSLSocketFactory.java


26a27
> import javax.net.SocketFactory;
74c75,77
<         return factory.createSocket();
---
>         // Does not work with SSL SNI: return factory.createSocket();
>         // Fix below:
>         return SocketFactory.getDefault().createSocket();
82c85,87
<         return factory.createSocket();
---
>         // Does not work with SSL SNI: return factory.createSocket();
>         // Fix below:
>         return SocketFactory.getDefault().createSocket();
Comment 8 Gordon McKinney 2016-02-02 00:57:44 UTC
NOTE: I am digging deeper on the fix listed above. It seems JMeter has buried the source of the socket factory somewhat in abstraction :-)
Comment 9 Philippe Mouawad 2016-02-02 21:51:11 UTC
Hello,
Thanks for your contribution(In reply to Gordon McKinney from comment #8)
> NOTE: I am digging deeper on the fix listed above. It seems JMeter has
> buried the source of the socket factory somewhat in abstraction :-)

Thanks for your contribution and help.
Yes we were aware it was not fixed yet, that's why bug was reopened.

I understand that for now fix is not yet complete right ?
Maybe I can help on JMeter code, what are you looking for ?
Thanks
Comment 10 Philippe Mouawad 2016-02-26 22:53:59 UTC
Author: pmouawad
Date: Fri Feb 26 22:35:18 2016
New Revision: 1732569

URL: http://svn.apache.org/viewvc?rev=1732569&view=rev
Log:
Upgrade to HttpClient/httpmime 4.5.2 which fixes at the same time:
- Bug 58881 - HTTP Request : HTTPHC4Impl shows exception when server uses "deflate" compression
- Bug 58583 - HTTP client fails to close connection if server misbehaves by not sending "connection: close", violating HTTP RFC 2616 / RFC 7230
- Bug 56358 - Cookie manager supports cross port cookies and RFC6265
- Bug 57319 - Upgrade to HttpClient 4.5.2
Bugzilla Id: 57319

Modified:
    jmeter/trunk/build.properties
    jmeter/trunk/eclipse.classpath
    jmeter/trunk/lib/   (props changed)
    jmeter/trunk/lib/aareadme.txt
    jmeter/trunk/licenses/bin/README.txt
    jmeter/trunk/res/maven/ApacheJMeter_parent.pom
    jmeter/trunk/test/src/org/apache/jmeter/protocol/http/control/TestCookieManager.java
    jmeter/trunk/test/src/org/apache/jmeter/protocol/http/sampler/TestHTTPSamplersAgainstHttpMirrorServer.java
    jmeter/trunk/xdocs/changes.xml
Comment 11 The ASF infrastructure team 2022-09-24 20:37:58 UTC
This issue has been migrated to GitHub: https://github.com/apache/jmeter/issues/3494