[jira] [Updated] (HTTPCLIENT-1952) Allow default User Agent to be disabled

2018-12-23 Thread Michael Osipov (JIRA)


 [ 
https://issues.apache.org/jira/browse/HTTPCLIENT-1952?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Michael Osipov updated HTTPCLIENT-1952:
---
Fix Version/s: 5.0 Beta4
   4.5.7

> Allow default User Agent to be disabled
> ---
>
> Key: HTTPCLIENT-1952
> URL: https://issues.apache.org/jira/browse/HTTPCLIENT-1952
> Project: HttpComponents HttpClient
>  Issue Type: Improvement
>  Components: HttpCache
>Affects Versions: 4.5.6
>Reporter: Antony Bowesman
>Assignee: Michael Osipov
>Priority: Minor
> Fix For: 4.5.7, 5.0 Beta4
>
>
> There is no way to disable the User-Agent header. In any kind of micro 
> service architecture, where UA header is irrelevant, the header cannot be 
> removed.
> This has been seen as an issue using JMeter, see link
> [https://bz.apache.org/bugzilla/show_bug.cgi?id=62977#c1]
> See comment #1 there from [~michael-o] 
>  



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

-
To unsubscribe, e-mail: dev-unsubscr...@hc.apache.org
For additional commands, e-mail: dev-h...@hc.apache.org



[GitHub] michael-o opened a new pull request #128: [HTTPCLIENT-1952] Allow default User Agent to be disabled

2018-12-23 Thread GitBox
michael-o opened a new pull request #128: [HTTPCLIENT-1952] Allow default User 
Agent to be disabled
URL: https://github.com/apache/httpcomponents-client/pull/128
 
 
   Naive Approach works for me. I am not certain whether the `@see` is 
necessary. I think not.


This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services

-
To unsubscribe, e-mail: dev-unsubscr...@hc.apache.org
For additional commands, e-mail: dev-h...@hc.apache.org



[jira] [Commented] (HTTPCLIENT-1952) Allow default User Agent to be disabled

2018-12-23 Thread Michael Osipov (JIRA)


[ 
https://issues.apache.org/jira/browse/HTTPCLIENT-1952?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16728044#comment-16728044
 ] 

Michael Osipov commented on HTTPCLIENT-1952:


I have now opened a PR for 5.0. No tests yet since I am not familiar where is 
the best place to test that.

> Allow default User Agent to be disabled
> ---
>
> Key: HTTPCLIENT-1952
> URL: https://issues.apache.org/jira/browse/HTTPCLIENT-1952
> Project: HttpComponents HttpClient
>  Issue Type: Improvement
>  Components: HttpCache
>Affects Versions: 4.5.6
>Reporter: Antony Bowesman
>Assignee: Michael Osipov
>Priority: Minor
> Fix For: 4.5.7, 5.0 Beta4
>
>  Time Spent: 10m
>  Remaining Estimate: 0h
>
> There is no way to disable the User-Agent header. In any kind of micro 
> service architecture, where UA header is irrelevant, the header cannot be 
> removed.
> This has been seen as an issue using JMeter, see link
> [https://bz.apache.org/bugzilla/show_bug.cgi?id=62977#c1]
> See comment #1 there from [~michael-o] 
>  



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

-
To unsubscribe, e-mail: dev-unsubscr...@hc.apache.org
For additional commands, e-mail: dev-h...@hc.apache.org



[jira] [Commented] (HTTPCLIENT-1952) Allow default User Agent to be disabled

2018-12-23 Thread ASF subversion and git services (JIRA)


[ 
https://issues.apache.org/jira/browse/HTTPCLIENT-1952?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16728043#comment-16728043
 ] 

ASF subversion and git services commented on HTTPCLIENT-1952:
-

Commit d252500411d7568e4453242c6db95e4d07444703 in httpcomponents-client's 
branch refs/heads/HTTPCLIENT-1952_5.0 from Michael Osipov
[ https://gitbox.apache.org/repos/asf?p=httpcomponents-client.git;h=d252500 ]

[HTTPCLIENT-1952] Allow default User Agent to be disabled


> Allow default User Agent to be disabled
> ---
>
> Key: HTTPCLIENT-1952
> URL: https://issues.apache.org/jira/browse/HTTPCLIENT-1952
> Project: HttpComponents HttpClient
>  Issue Type: Improvement
>  Components: HttpCache
>Affects Versions: 4.5.6
>Reporter: Antony Bowesman
>Assignee: Michael Osipov
>Priority: Minor
> Fix For: 4.5.7, 5.0 Beta4
>
>
> There is no way to disable the User-Agent header. In any kind of micro 
> service architecture, where UA header is irrelevant, the header cannot be 
> removed.
> This has been seen as an issue using JMeter, see link
> [https://bz.apache.org/bugzilla/show_bug.cgi?id=62977#c1]
> See comment #1 there from [~michael-o] 
>  



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

-
To unsubscribe, e-mail: dev-unsubscr...@hc.apache.org
For additional commands, e-mail: dev-h...@hc.apache.org



[GitHub] thc202 commented on issue #128: [HTTPCLIENT-1952] Allow default User Agent to be disabled

2018-12-23 Thread GitBox
thc202 commented on issue #128: [HTTPCLIENT-1952] Allow default User Agent to 
be disabled
URL: 
https://github.com/apache/httpcomponents-client/pull/128#issuecomment-449661812
 
 
   It seems you didn't commit all changes (`defaultUserAgentDisabled` is not 
used).


This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services

-
To unsubscribe, e-mail: dev-unsubscr...@hc.apache.org
For additional commands, e-mail: dev-h...@hc.apache.org



[jira] [Commented] (HTTPCLIENT-1952) Allow default User Agent to be disabled

2018-12-23 Thread ASF subversion and git services (JIRA)


[ 
https://issues.apache.org/jira/browse/HTTPCLIENT-1952?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16728053#comment-16728053
 ] 

ASF subversion and git services commented on HTTPCLIENT-1952:
-

Commit 2017fc74e4a5df67083886ecdb553564e5747f8f in httpcomponents-client's 
branch refs/heads/HTTPCLIENT-1952_5.0 from Michael Osipov
[ https://gitbox.apache.org/repos/asf?p=httpcomponents-client.git;h=2017fc7 ]

[HTTPCLIENT-1952] Allow default User Agent to be disabled


> Allow default User Agent to be disabled
> ---
>
> Key: HTTPCLIENT-1952
> URL: https://issues.apache.org/jira/browse/HTTPCLIENT-1952
> Project: HttpComponents HttpClient
>  Issue Type: Improvement
>  Components: HttpCache
>Affects Versions: 4.5.6
>Reporter: Antony Bowesman
>Assignee: Michael Osipov
>Priority: Minor
> Fix For: 4.5.7, 5.0 Beta4
>
>  Time Spent: 20m
>  Remaining Estimate: 0h
>
> There is no way to disable the User-Agent header. In any kind of micro 
> service architecture, where UA header is irrelevant, the header cannot be 
> removed.
> This has been seen as an issue using JMeter, see link
> [https://bz.apache.org/bugzilla/show_bug.cgi?id=62977#c1]
> See comment #1 there from [~michael-o] 
>  



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

-
To unsubscribe, e-mail: dev-unsubscr...@hc.apache.org
For additional commands, e-mail: dev-h...@hc.apache.org



[GitHub] michael-o commented on issue #128: [HTTPCLIENT-1952] Allow default User Agent to be disabled

2018-12-23 Thread GitBox
michael-o commented on issue #128: [HTTPCLIENT-1952] Allow default User Agent 
to be disabled
URL: 
https://github.com/apache/httpcomponents-client/pull/128#issuecomment-449662106
 
 
   @thc202 Thanks, missed that in the interactive add.


This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services

-
To unsubscribe, e-mail: dev-unsubscr...@hc.apache.org
For additional commands, e-mail: dev-h...@hc.apache.org



[GitHub] michael-o commented on issue #128: [HTTPCLIENT-1952] Allow default User Agent to be disabled

2018-12-23 Thread GitBox
michael-o commented on issue #128: [HTTPCLIENT-1952] Allow default User Agent 
to be disabled
URL: 
https://github.com/apache/httpcomponents-client/pull/128#issuecomment-449662138
 
 
   One would also need to change the `@since` if we backport this to 4.5.x.


This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services

-
To unsubscribe, e-mail: dev-unsubscr...@hc.apache.org
For additional commands, e-mail: dev-h...@hc.apache.org



[GitHub] michael-o opened a new pull request #129: Improve HttpResponseException#getMessage()

2018-12-23 Thread GitBox
michael-o opened a new pull request #129: Improve 
HttpResponseException#getMessage()
URL: https://github.com/apache/httpcomponents-client/pull/129
 
 
   The #getMessage() now properly consists of the status code as such and the
   optional reason phrase. Moreover, the pure reason phrase can be retrieved
   via #getReasonPhrase.
   
   This is an improved version of #126.


This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services

-
To unsubscribe, e-mail: dev-unsubscr...@hc.apache.org
For additional commands, e-mail: dev-h...@hc.apache.org



Minimal client sending "Connection: keep-alive"

2018-12-23 Thread Michael Osipov

Folks,

why does a minimal client:

HttpClientBuilder bulder = 
HttpClientBuilder.create().disableContentCompression();
CloseableHttpClient client = bulder.build();
CloseableHttpResponse resp = client.execute(new HttpGet("https://google.de";));
EntityUtils.consumeQuietly(resp.getEntity());


still send the "Connection: keep-alive" request header? This seems like 
wasted bytes for HTTP/1.1. Is that really for backwards compat? Aren't 
we good to break (remove) this in 5.0?



[main] DEBUG org.apache.hc.client5.http.impl.io.DefaultHttpClientConnectionOperator - 
Connection established 192.168.1.13:52724<->216.58.210.3:443
[main] DEBUG org.apache.hc.client5.http.impl.classic.MainClientExec - Executing 
request GET / HTTP/1.1
[main] DEBUG org.apache.hc.client5.http.headers - http-outgoing-0 >> GET / 
HTTP/1.1
[main] DEBUG org.apache.hc.client5.http.headers - http-outgoing-0 >> Host: 
google.de
[main] DEBUG org.apache.hc.client5.http.headers - http-outgoing-0 >> 
Connection: keep-alive
[main] DEBUG org.apache.hc.client5.http.headers - http-outgoing-0 >> 
User-Agent: Apache-HttpClient/5.0-beta4-SNAPSHOT (Java/1.7.0_191)


Michael

-
To unsubscribe, e-mail: dev-unsubscr...@hc.apache.org
For additional commands, e-mail: dev-h...@hc.apache.org



[GitHub] ok2c closed pull request #129: Improve HttpResponseException#getMessage()

2018-12-23 Thread GitBox
ok2c closed pull request #129: Improve HttpResponseException#getMessage()
URL: https://github.com/apache/httpcomponents-client/pull/129
 
 
   


This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services

-
To unsubscribe, e-mail: dev-unsubscr...@hc.apache.org
For additional commands, e-mail: dev-h...@hc.apache.org



[GitHub] michael-o commented on issue #129: Improve HttpResponseException#getMessage()

2018-12-23 Thread GitBox
michael-o commented on issue #129: Improve HttpResponseException#getMessage()
URL: 
https://github.com/apache/httpcomponents-client/pull/129#issuecomment-449666384
 
 
@ok2c shall I backport to 4.5.x?


This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services

-
To unsubscribe, e-mail: dev-unsubscr...@hc.apache.org
For additional commands, e-mail: dev-h...@hc.apache.org



[GitHub] ok2c commented on issue #129: Improve HttpResponseException#getMessage()

2018-12-23 Thread GitBox
ok2c commented on issue #129: Improve HttpResponseException#getMessage()
URL: 
https://github.com/apache/httpcomponents-client/pull/129#issuecomment-449666435
 
 
   @michael-o Up to you. I do not feel very strongly about this change. 


This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services

-
To unsubscribe, e-mail: dev-unsubscr...@hc.apache.org
For additional commands, e-mail: dev-h...@hc.apache.org



[GitHub] ok2c commented on issue #128: [HTTPCLIENT-1952] Allow default User Agent to be disabled

2018-12-23 Thread GitBox
ok2c commented on issue #128: [HTTPCLIENT-1952] Allow default User Agent to be 
disabled
URL: 
https://github.com/apache/httpcomponents-client/pull/128#issuecomment-449666545
 
 
   @michael-o Ideally `RequestUserAgent` should be removed from the message 
processing chain entirely but looks good enough to me.


This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services

-
To unsubscribe, e-mail: dev-unsubscr...@hc.apache.org
For additional commands, e-mail: dev-h...@hc.apache.org



Re: Minimal client sending "Connection: keep-alive"

2018-12-23 Thread Oleg Kalnichevski
On Sun, 2018-12-23 at 22:07 +0100, Michael Osipov wrote:
> Folks,
> 
> why does a minimal client:
> > HttpClientBuilder bulder =
> > HttpClientBuilder.create().disableContentCompression();
> > CloseableHttpClient client = bulder.build();
> > CloseableHttpResponse resp = client.execute(new HttpGet("
> > https://google.de";));
> > EntityUtils.consumeQuietly(resp.getEntity());
> 
> still send the "Connection: keep-alive" request header? This seems
> like 
> wasted bytes for HTTP/1.1. Is that really for backwards compat?
> Aren't 
> we good to break (remove) this in 5.0?
> 

It is mostly for the sake of compatibility. I am fine with dropping the
header for HTTP/1.1 connections, though I see no harm in keeping it.

Oleg

> > [main] DEBUG
> > org.apache.hc.client5.http.impl.io.DefaultHttpClientConnectionOpera
> > tor - Connection established 192.168.1.13:52724<->216.58.210.3:443
> > [main] DEBUG org.apache.hc.client5.http.impl.classic.MainClientExec
> > - Executing request GET / HTTP/1.1
> > [main] DEBUG org.apache.hc.client5.http.headers - http-outgoing-0
> > >> GET / HTTP/1.1
> > [main] DEBUG org.apache.hc.client5.http.headers - http-outgoing-0
> > >> Host: google.de
> > [main] DEBUG org.apache.hc.client5.http.headers - http-outgoing-0
> > >> Connection: keep-alive
> > [main] DEBUG org.apache.hc.client5.http.headers - http-outgoing-0
> > >> User-Agent: Apache-HttpClient/5.0-beta4-SNAPSHOT
> > (Java/1.7.0_191)
> 
> Michael
> 
> -
> To unsubscribe, e-mail: dev-unsubscr...@hc.apache.org
> For additional commands, e-mail: dev-h...@hc.apache.org
> 


-
To unsubscribe, e-mail: dev-unsubscr...@hc.apache.org
For additional commands, e-mail: dev-h...@hc.apache.org



[GitHub] michael-o commented on issue #128: [HTTPCLIENT-1952] Allow default User Agent to be disabled

2018-12-23 Thread GitBox
michael-o commented on issue #128: [HTTPCLIENT-1952] Allow default User Agent 
to be disabled
URL: 
https://github.com/apache/httpcomponents-client/pull/128#issuecomment-449666799
 
 
@ok2c That is true, but that would require if clauses around 
`execChainDefinition.addFirst` and `b.addAll(.., new 
RequestUserAgent(userAgentCopy), new RequestExpectContinue());` and make the 
code less readable. I think this is a good compromise given that most people 
won't disable this header.


This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services

-
To unsubscribe, e-mail: dev-unsubscr...@hc.apache.org
For additional commands, e-mail: dev-h...@hc.apache.org



[GitHub] ok2c commented on issue #128: [HTTPCLIENT-1952] Allow default User Agent to be disabled

2018-12-23 Thread GitBox
ok2c commented on issue #128: [HTTPCLIENT-1952] Allow default User Agent to be 
disabled
URL: 
https://github.com/apache/httpcomponents-client/pull/128#issuecomment-449666847
 
 
   @michael-o Agreed.


This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services

-
To unsubscribe, e-mail: dev-unsubscr...@hc.apache.org
For additional commands, e-mail: dev-h...@hc.apache.org



[GitHub] ok2c commented on issue #128: [HTTPCLIENT-1952] Allow default User Agent to be disabled

2018-12-23 Thread GitBox
ok2c commented on issue #128: [HTTPCLIENT-1952] Allow default User Agent to be 
disabled
URL: 
https://github.com/apache/httpcomponents-client/pull/128#issuecomment-449666855
 
 
   @michael-o Feel free to merge the PR.


This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services

-
To unsubscribe, e-mail: dev-unsubscr...@hc.apache.org
For additional commands, e-mail: dev-h...@hc.apache.org



[GitHub] michael-o commented on issue #128: [HTTPCLIENT-1952] Allow default User Agent to be disabled

2018-12-23 Thread GitBox
michael-o commented on issue #128: [HTTPCLIENT-1952] Allow default User Agent 
to be disabled
URL: 
https://github.com/apache/httpcomponents-client/pull/128#issuecomment-449667069
 
 
   Will do in a Moment and prepare 4.5.x PR.


This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services

-
To unsubscribe, e-mail: dev-unsubscr...@hc.apache.org
For additional commands, e-mail: dev-h...@hc.apache.org



[GitHub] michael-o opened a new pull request #130: Improve HttpResponseException#getMessage()

2018-12-23 Thread GitBox
michael-o opened a new pull request #130: Improve 
HttpResponseException#getMessage()
URL: https://github.com/apache/httpcomponents-client/pull/130
 
 
   The #getMessage() now properly consists of the status code as such and the
   optional reason phrase. Moreover, the pure reason phrase can be retrieved
   via #getReasonPhrase.


This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services

-
To unsubscribe, e-mail: dev-unsubscr...@hc.apache.org
For additional commands, e-mail: dev-h...@hc.apache.org



[jira] [Commented] (HTTPCLIENT-1952) Allow default User Agent to be disabled

2018-12-23 Thread ASF subversion and git services (JIRA)


[ 
https://issues.apache.org/jira/browse/HTTPCLIENT-1952?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16728067#comment-16728067
 ] 

ASF subversion and git services commented on HTTPCLIENT-1952:
-

Commit 354ae3586ebb2557fece463c322cf2d1cc128baa in httpcomponents-client's 
branch refs/heads/master from Michael Osipov
[ https://gitbox.apache.org/repos/asf?p=httpcomponents-client.git;h=354ae35 ]

[HTTPCLIENT-1952] Allow default User Agent to be disabled

This closes #128


> Allow default User Agent to be disabled
> ---
>
> Key: HTTPCLIENT-1952
> URL: https://issues.apache.org/jira/browse/HTTPCLIENT-1952
> Project: HttpComponents HttpClient
>  Issue Type: Improvement
>  Components: HttpCache
>Affects Versions: 4.5.6
>Reporter: Antony Bowesman
>Assignee: Michael Osipov
>Priority: Minor
> Fix For: 4.5.7, 5.0 Beta4
>
>  Time Spent: 1.5h
>  Remaining Estimate: 0h
>
> There is no way to disable the User-Agent header. In any kind of micro 
> service architecture, where UA header is irrelevant, the header cannot be 
> removed.
> This has been seen as an issue using JMeter, see link
> [https://bz.apache.org/bugzilla/show_bug.cgi?id=62977#c1]
> See comment #1 there from [~michael-o] 
>  



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

-
To unsubscribe, e-mail: dev-unsubscr...@hc.apache.org
For additional commands, e-mail: dev-h...@hc.apache.org



[GitHub] asfgit closed pull request #128: [HTTPCLIENT-1952] Allow default User Agent to be disabled

2018-12-23 Thread GitBox
asfgit closed pull request #128: [HTTPCLIENT-1952] Allow default User Agent to 
be disabled
URL: https://github.com/apache/httpcomponents-client/pull/128
 
 
   


This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services

-
To unsubscribe, e-mail: dev-unsubscr...@hc.apache.org
For additional commands, e-mail: dev-h...@hc.apache.org



[jira] [Commented] (HTTPCLIENT-1952) Allow default User Agent to be disabled

2018-12-23 Thread ASF subversion and git services (JIRA)


[ 
https://issues.apache.org/jira/browse/HTTPCLIENT-1952?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16728064#comment-16728064
 ] 

ASF subversion and git services commented on HTTPCLIENT-1952:
-

Commit eba3b9eda4a50182617ee24e8ef4ca63cd0011be in httpcomponents-client's 
branch refs/heads/HTTPCLIENT-1952_5.0 from Michael Osipov
[ https://gitbox.apache.org/repos/asf?p=httpcomponents-client.git;h=eba3b9e ]

[HTTPCLIENT-1952] Allow default User Agent to be disabled

This closes #128


> Allow default User Agent to be disabled
> ---
>
> Key: HTTPCLIENT-1952
> URL: https://issues.apache.org/jira/browse/HTTPCLIENT-1952
> Project: HttpComponents HttpClient
>  Issue Type: Improvement
>  Components: HttpCache
>Affects Versions: 4.5.6
>Reporter: Antony Bowesman
>Assignee: Michael Osipov
>Priority: Minor
> Fix For: 4.5.7, 5.0 Beta4
>
>  Time Spent: 1.5h
>  Remaining Estimate: 0h
>
> There is no way to disable the User-Agent header. In any kind of micro 
> service architecture, where UA header is irrelevant, the header cannot be 
> removed.
> This has been seen as an issue using JMeter, see link
> [https://bz.apache.org/bugzilla/show_bug.cgi?id=62977#c1]
> See comment #1 there from [~michael-o] 
>  



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

-
To unsubscribe, e-mail: dev-unsubscr...@hc.apache.org
For additional commands, e-mail: dev-h...@hc.apache.org



[GitHub] michael-o closed pull request #130: Improve HttpResponseException#getMessage()

2018-12-23 Thread GitBox
michael-o closed pull request #130: Improve HttpResponseException#getMessage()
URL: https://github.com/apache/httpcomponents-client/pull/130
 
 
   


This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services

-
To unsubscribe, e-mail: dev-unsubscr...@hc.apache.org
For additional commands, e-mail: dev-h...@hc.apache.org



[jira] [Commented] (HTTPCLIENT-1952) Allow default User Agent to be disabled

2018-12-23 Thread ASF subversion and git services (JIRA)


[ 
https://issues.apache.org/jira/browse/HTTPCLIENT-1952?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16728065#comment-16728065
 ] 

ASF subversion and git services commented on HTTPCLIENT-1952:
-

Commit 354ae3586ebb2557fece463c322cf2d1cc128baa in httpcomponents-client's 
branch refs/heads/HTTPCLIENT-1952_5.0 from Michael Osipov
[ https://gitbox.apache.org/repos/asf?p=httpcomponents-client.git;h=354ae35 ]

[HTTPCLIENT-1952] Allow default User Agent to be disabled

This closes #128


> Allow default User Agent to be disabled
> ---
>
> Key: HTTPCLIENT-1952
> URL: https://issues.apache.org/jira/browse/HTTPCLIENT-1952
> Project: HttpComponents HttpClient
>  Issue Type: Improvement
>  Components: HttpCache
>Affects Versions: 4.5.6
>Reporter: Antony Bowesman
>Assignee: Michael Osipov
>Priority: Minor
> Fix For: 4.5.7, 5.0 Beta4
>
>  Time Spent: 1.5h
>  Remaining Estimate: 0h
>
> There is no way to disable the User-Agent header. In any kind of micro 
> service architecture, where UA header is irrelevant, the header cannot be 
> removed.
> This has been seen as an issue using JMeter, see link
> [https://bz.apache.org/bugzilla/show_bug.cgi?id=62977#c1]
> See comment #1 there from [~michael-o] 
>  



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

-
To unsubscribe, e-mail: dev-unsubscr...@hc.apache.org
For additional commands, e-mail: dev-h...@hc.apache.org



[jira] [Commented] (HTTPCLIENT-1952) Allow default User Agent to be disabled

2018-12-23 Thread ASF subversion and git services (JIRA)


[ 
https://issues.apache.org/jira/browse/HTTPCLIENT-1952?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16728071#comment-16728071
 ] 

ASF subversion and git services commented on HTTPCLIENT-1952:
-

Commit f04d81e3026c143f2764b10c2f83f85f5c1b3d3c in httpcomponents-client's 
branch refs/heads/HTTPCLIENT-1952_4.5 from Michael Osipov
[ https://gitbox.apache.org/repos/asf?p=httpcomponents-client.git;h=f04d81e ]

[HTTPCLIENT-1952] Allow default User Agent to be disabled


> Allow default User Agent to be disabled
> ---
>
> Key: HTTPCLIENT-1952
> URL: https://issues.apache.org/jira/browse/HTTPCLIENT-1952
> Project: HttpComponents HttpClient
>  Issue Type: Improvement
>  Components: HttpCache
>Affects Versions: 4.5.6
>Reporter: Antony Bowesman
>Assignee: Michael Osipov
>Priority: Minor
> Fix For: 4.5.7, 5.0 Beta4
>
>  Time Spent: 1h 40m
>  Remaining Estimate: 0h
>
> There is no way to disable the User-Agent header. In any kind of micro 
> service architecture, where UA header is irrelevant, the header cannot be 
> removed.
> This has been seen as an issue using JMeter, see link
> [https://bz.apache.org/bugzilla/show_bug.cgi?id=62977#c1]
> See comment #1 there from [~michael-o] 
>  



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

-
To unsubscribe, e-mail: dev-unsubscr...@hc.apache.org
For additional commands, e-mail: dev-h...@hc.apache.org



[GitHub] michael-o opened a new pull request #131: [HTTPCLIENT-1952] Allow default User Agent to be disabled

2018-12-23 Thread GitBox
michael-o opened a new pull request #131: [HTTPCLIENT-1952] Allow default User 
Agent to be disabled
URL: https://github.com/apache/httpcomponents-client/pull/131
 
 
   


This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services

-
To unsubscribe, e-mail: dev-unsubscr...@hc.apache.org
For additional commands, e-mail: dev-h...@hc.apache.org



[GitHub] asfgit closed pull request #131: [HTTPCLIENT-1952] Allow default User Agent to be disabled

2018-12-23 Thread GitBox
asfgit closed pull request #131: [HTTPCLIENT-1952] Allow default User Agent to 
be disabled
URL: https://github.com/apache/httpcomponents-client/pull/131
 
 
   


This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services

-
To unsubscribe, e-mail: dev-unsubscr...@hc.apache.org
For additional commands, e-mail: dev-h...@hc.apache.org



[jira] [Commented] (HTTPCLIENT-1952) Allow default User Agent to be disabled

2018-12-23 Thread Michael Osipov (JIRA)


[ 
https://issues.apache.org/jira/browse/HTTPCLIENT-1952?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16728073#comment-16728073
 ] 

Michael Osipov commented on HTTPCLIENT-1952:


Implemented in master and 4.5.x.

> Allow default User Agent to be disabled
> ---
>
> Key: HTTPCLIENT-1952
> URL: https://issues.apache.org/jira/browse/HTTPCLIENT-1952
> Project: HttpComponents HttpClient
>  Issue Type: Improvement
>  Components: HttpCache
>Affects Versions: 4.5.6
>Reporter: Antony Bowesman
>Assignee: Michael Osipov
>Priority: Minor
> Fix For: 4.5.7, 5.0 Beta4
>
>  Time Spent: 2h
>  Remaining Estimate: 0h
>
> There is no way to disable the User-Agent header. In any kind of micro 
> service architecture, where UA header is irrelevant, the header cannot be 
> removed.
> This has been seen as an issue using JMeter, see link
> [https://bz.apache.org/bugzilla/show_bug.cgi?id=62977#c1]
> See comment #1 there from [~michael-o] 
>  



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

-
To unsubscribe, e-mail: dev-unsubscr...@hc.apache.org
For additional commands, e-mail: dev-h...@hc.apache.org



[jira] [Closed] (HTTPCLIENT-1952) Allow default User Agent to be disabled

2018-12-23 Thread Michael Osipov (JIRA)


 [ 
https://issues.apache.org/jira/browse/HTTPCLIENT-1952?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Michael Osipov closed HTTPCLIENT-1952.
--
Resolution: Fixed

> Allow default User Agent to be disabled
> ---
>
> Key: HTTPCLIENT-1952
> URL: https://issues.apache.org/jira/browse/HTTPCLIENT-1952
> Project: HttpComponents HttpClient
>  Issue Type: Improvement
>  Components: HttpCache
>Affects Versions: 4.5.6
>Reporter: Antony Bowesman
>Assignee: Michael Osipov
>Priority: Minor
> Fix For: 4.5.7, 5.0 Beta4
>
>  Time Spent: 2h
>  Remaining Estimate: 0h
>
> There is no way to disable the User-Agent header. In any kind of micro 
> service architecture, where UA header is irrelevant, the header cannot be 
> removed.
> This has been seen as an issue using JMeter, see link
> [https://bz.apache.org/bugzilla/show_bug.cgi?id=62977#c1]
> See comment #1 there from [~michael-o] 
>  



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

-
To unsubscribe, e-mail: dev-unsubscr...@hc.apache.org
For additional commands, e-mail: dev-h...@hc.apache.org



[jira] [Commented] (HTTPCLIENT-1952) Allow default User Agent to be disabled

2018-12-23 Thread ASF subversion and git services (JIRA)


[ 
https://issues.apache.org/jira/browse/HTTPCLIENT-1952?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16728072#comment-16728072
 ] 

ASF subversion and git services commented on HTTPCLIENT-1952:
-

Commit f04d81e3026c143f2764b10c2f83f85f5c1b3d3c in httpcomponents-client's 
branch refs/heads/4.5.x from Michael Osipov
[ https://gitbox.apache.org/repos/asf?p=httpcomponents-client.git;h=f04d81e ]

[HTTPCLIENT-1952] Allow default User Agent to be disabled


> Allow default User Agent to be disabled
> ---
>
> Key: HTTPCLIENT-1952
> URL: https://issues.apache.org/jira/browse/HTTPCLIENT-1952
> Project: HttpComponents HttpClient
>  Issue Type: Improvement
>  Components: HttpCache
>Affects Versions: 4.5.6
>Reporter: Antony Bowesman
>Assignee: Michael Osipov
>Priority: Minor
> Fix For: 4.5.7, 5.0 Beta4
>
>  Time Spent: 1h 50m
>  Remaining Estimate: 0h
>
> There is no way to disable the User-Agent header. In any kind of micro 
> service architecture, where UA header is irrelevant, the header cannot be 
> removed.
> This has been seen as an issue using JMeter, see link
> [https://bz.apache.org/bugzilla/show_bug.cgi?id=62977#c1]
> See comment #1 there from [~michael-o] 
>  



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

-
To unsubscribe, e-mail: dev-unsubscr...@hc.apache.org
For additional commands, e-mail: dev-h...@hc.apache.org



Re: Minimal client sending "Connection: keep-alive"

2018-12-23 Thread Michael Osipov

Am 2018-12-23 um 23:21 schrieb Oleg Kalnichevski:

On Sun, 2018-12-23 at 22:07 +0100, Michael Osipov wrote:

Folks,

why does a minimal client:

HttpClientBuilder bulder =
HttpClientBuilder.create().disableContentCompression();
CloseableHttpClient client = bulder.build();
CloseableHttpResponse resp = client.execute(new HttpGet("
https://google.de";));
EntityUtils.consumeQuietly(resp.getEntity());


still send the "Connection: keep-alive" request header? This seems
like
wasted bytes for HTTP/1.1. Is that really for backwards compat?
Aren't
we good to break (remove) this in 5.0?



It is mostly for the sake of compatibility. I am fine with dropping the
header for HTTP/1.1 connections, though I see no harm in keeping it.


Right, there is no harm, but also no benefit and just wasted bytes for 
HTTP/1.1.
As far as I can see, it is RequestConnControl. I have created a branch 
(drop-http11-keep-alive) with a first shot of changes. I am not yet 
happy with the remaining test method names because they do not reflect 
the truth now. I am also not really happy with "Proxy-Connection" 
because RFC 7231 says in A.1.2: "As a result, clients are encouraged not 
to send the Proxy-Connection header field in any requests." Is that good 
reason to drop this "Proxy-Connection" fiddling in client and core 
altogether?


Show I also apply this change to 
httpcore5/src/main/java/org/apache/hc/core5/http/protocol/RequestConnControl.java?


Michael

-
To unsubscribe, e-mail: dev-unsubscr...@hc.apache.org
For additional commands, e-mail: dev-h...@hc.apache.org



Re: Minimal client sending "Connection: keep-alive"

2018-12-23 Thread Michael Osipov

Am 2018-12-24 um 01:05 schrieb Michael Osipov:

Am 2018-12-23 um 23:21 schrieb Oleg Kalnichevski:

On Sun, 2018-12-23 at 22:07 +0100, Michael Osipov wrote:

Folks,

why does a minimal client:

HttpClientBuilder bulder =
HttpClientBuilder.create().disableContentCompression();
CloseableHttpClient client = bulder.build();
CloseableHttpResponse resp = client.execute(new HttpGet("
https://google.de";));
EntityUtils.consumeQuietly(resp.getEntity());


still send the "Connection: keep-alive" request header? This seems
like
wasted bytes for HTTP/1.1. Is that really for backwards compat?
Aren't
we good to break (remove) this in 5.0?



It is mostly for the sake of compatibility. I am fine with dropping the
header for HTTP/1.1 connections, though I see no harm in keeping it.


Right, there is no harm, but also no benefit and just wasted bytes for 
HTTP/1.1.
As far as I can see, it is RequestConnControl. I have created a branch 
(drop-http11-keep-alive) with a first shot of changes. I am not yet 
happy with the remaining test method names because they do not reflect 
the truth now. I am also not really happy with "Proxy-Connection" 
because RFC 7231 says in A.1.2: "As a result, clients are encouraged not 
to send the Proxy-Connection header field in any requests." Is that good 
reason to drop this "Proxy-Connection" fiddling in client and core 
altogether?


Alternatively, this entire class could check the HTTP version first, or 
it is removed from the default chain and the user has to add this if he 
wants to use HTTP/1.1?


Michael

-
To unsubscribe, e-mail: dev-unsubscr...@hc.apache.org
For additional commands, e-mail: dev-h...@hc.apache.org