Hi Oleg, I think I understand why it was not integrated to 4.4.x branch, signature of DefaultConnectionReuseStrategy#keepAlive did not contain request.
I have submitted a PR for 4.4.x: https://github.com/apache/httpcore/pull/19 it works for our need but it is not complete as context.getAttribute(HttpCoreContext.HTTP_REQUEST); in some call paths. Can we add without risk the call to localContext.setAttribute(HttpCoreContext.HTTP_REQUEST, HttpRequest ) before keepAlive calls or could it introduce issues ? Thanks On Wed, Dec 30, 2015 at 3:01 PM, Philippe Mouawad < philippe.moua...@gmail.com> wrote: > Hi Oleg, > Thanks for answer. > > Why is the fix not in 4.4.4 ? From commit date and release date of 4.4.4, > I would say it should have been no ? > > Bug from JIRA https://issues.apache.org/jira/browse/HTTPCORE-397, I see > fixVersion is 5.0-alpha1 but piece of code is not in 4.4.4 > > > Thanks > > On Wed, Dec 30, 2015 at 10:53 AM, Oleg Kalnichevski <ol...@apache.org> > wrote: > >> On Tue, 2015-12-29 at 17:34 +0100, Philippe Mouawad wrote: >> > Hello, >> > We have a bug report in JMeter : >> > https://bz.apache.org/bugzilla/show_bug.cgi?id=58583 >> > >> > To summarize, setting "Connection: close" header in the requests does >> not >> > make HttpClient close the connection on the client side. >> > >> > It seems to be a violation of RFC 2616: >> > http://tools.ietf.org/html/rfc2616#page-45 >> > http://tools.ietf.org/html/rfc2616#section-14.10 >> > >> > >> > And RFC7230: >> > http://tools.ietf.org/html/rfc7230#section-6.1 >> > >> > >> > I am not sure what to think about this. >> > >> >> Yes, it is a bug. It has been fixed in the trunk >> >> >> https://github.com/apache/httpcore/commit/7f6dc0fdbe1b84e43b78e86229917881f0e2252a >> >> Generally the server is expected to send 'connection: close' in response >> to 'connection: close' in the request. >> >> Oleg >> >> > > > -- > Cordialement. > Philippe Mouawad. > > > -- Cordialement. Philippe Mouawad.