Re: Missing settings for HttpClient timeouts ?

2024-02-22 Thread Oleg Kalnichevski
On 22/02/2024 13:16, Óscar Frías Barranco wrote: Thanks for your reply. I have activated HttpClient logs and it looks like, at least in this case, time is spent in DNS resolution. Is there a way to set a timeout for this (at the HttpClient level if that's possible, or at the OS level otherwise

Re: Missing settings for HttpClient timeouts ?

2024-02-22 Thread Óscar Frías Barranco
Thanks for your reply. I have activated HttpClient logs and it looks like, at least in this case, time is spent in DNS resolution. Is there a way to set a timeout for this (at the HttpClient level if that's possible, or at the OS level otherwise) ? Feb 22, 2024 1:10:24 PM org.apache.hc.client5

Re: Missing settings for HttpClient timeouts ?

2024-02-22 Thread Oleg Kalnichevski
On 22/02/2024 11:53, Óscar Frías Barranco wrote: Hello. I am trying to configure HttpClient to validate a list of URLs and I don't want it to take longer than 10 seconds for each URL. I have been searching for all available timeout settings in HttpClient but, even after setting them all to 2

Missing settings for HttpClient timeouts ?

2024-02-22 Thread Óscar Frías Barranco
Hello. I am trying to configure HttpClient to validate a list of URLs and I don't want it to take longer than 10 seconds for each URL. I have been searching for all available timeout settings in HttpClient but, even after setting them all to 2 seconds, HttpClient still takes longer than 10

Re: HTTP/2 Support with HttpClient Classic API

2023-07-22 Thread Oleg Kalnichevski
t; > support HTTP/2. > > > > Although I do agree that the full power of HTTP/2 can only be > > unleashed with an asynchronous API I still think that for simple > > use cases the blocking APIs should also support HTTP/2. > > I cannot really judge how complex such an implemen

Re: HTTP/2 Support with HttpClient Classic API

2023-07-21 Thread Konrad Windszus
l think that for simple use cases the blocking APIs > should also support HTTP/2. > I cannot really judge how complex such an implementation would be. > > In order to track this, I have opened > https://issues.apache.org/jira/browse/HTTPCLIENT-2286. > > Thanks, > Konrad

Re: HTTP/2 Support with HttpClient Classic API

2023-07-21 Thread Konrad Windszus
have opened https://issues.apache.org/jira/browse/HTTPCLIENT-2286. Thanks, Konrad > On 20. Jul 2023, at 20:59, Oleg Kalnichevski wrote: > > On Thu, 2023-07-20 at 15:13 +0200, Konrad Windszus wrote: >> Hi, >> Currently from reading >> https://hc.apache.org/httpcompon

Re: HTTP/2 Support with HttpClient Classic API

2023-07-20 Thread Oleg Kalnichevski
-term. In my personal opinion the use of HTTP/2 at its full potential requires event driven (async) programming interface incompatible with the InputStream / OutputStream based APIs. Oleg ----- To unsubscribe, e-mail: htt

HTTP/2 Support with HttpClient Classic API

2023-07-20 Thread Konrad Windszus
Hi, Currently from reading https://hc.apache.org/httpcomponents-client-5.2.x/ it seems that there are no limitations with support of HTTP/2, on the other hand only Async API has explicit HTTP/2 examples mentioned in https://hc.apache.org/httpcomponents-client-5.2.x/examples-async.html. Does the

HttpClient 5.2.2 release plans; Re: [ANNOUNCEMENT] HttpComponents Core 5.2.2 GA released

2023-07-18 Thread Oleg Kalnichevski
On Tue, 2023-07-18 at 10:22 +0530, Sandeep Gaur wrote: > Hi All, > > We need to update httpclient with the fix of > https://issues.apache.org/jira/browse/HTTPCORE-751, can someone > please > confirm the release plan of httpclient 5.2.2. > There are no immediate plans to rel

Re: Preemptive Basic auth with Apache HttpClient 5.2

2023-07-14 Thread D'Ascola, Giovanni
OK, your code uses an ExecInterceptor though, not a HttpRequestInterceptor. I’ll give it a try. Cheers Giovanni From: Oleg Kalnichevski Date: Friday, 14 July 2023 at 10:24 To: HttpClient User Discussion Subject: Re: Preemptive Basic auth with Apache HttpClient 5.2 On Thu, 2023-07-13 at 17:37

Re: Preemptive Basic auth with Apache HttpClient 5.2

2023-07-14 Thread Oleg Kalnichevski
I’d rather let the framework take > care of that. > It does. Oleg --- final HttpHost target = new HttpHost("http", "httpbin.org", 80); try (final CloseableHttpClient httpclient = HttpClients.custom() .addExecInterceptorBefore(ChainElement.PROTOCOL.n

Re: Preemptive Basic auth with Apache HttpClient 5.2

2023-07-13 Thread D'Ascola, Giovanni
July 2023 at 18:29 To: HttpClient User Discussion Subject: Re: Preemptive Basic auth with Apache HttpClient 5.2 On Thu, 2023-07-13 at 17:02 +, D'Ascola, Giovanni wrote: > I did look at the examples, but the Preemptive Basic Auth > one<https://eur02.safelinks.protection.outlook.com/?url

Re: Preemptive Basic auth with Apache HttpClient 5.2

2023-07-13 Thread Oleg Kalnichevski
entication.java> requires to manually create and > configure a context and pass it to the HttpClient.execute() method > every time. Apart from that not being very convenient, it wouldn’t > work with RestTemplate, as it uses HttpClient as its underlying > client and you don’t call the

Re: Preemptive Basic auth with Apache HttpClient 5.2

2023-07-13 Thread D'Ascola, Giovanni
d pass it to the HttpClient.execute() method every time. Apart from that not being very convenient, it wouldn’t work with RestTemplate, as it uses HttpClient as its underlying client and you don’t call the HttpClient.execute() directly. Giovanni From: Oleg Kalnichevski Date: Thursday, 13 July 2023 at

Re: Preemptive Basic auth with Apache HttpClient 5.2

2023-07-13 Thread Oleg Kalnichevski
On Thu, 2023-07-13 at 15:27 +, D'Ascola, Giovanni wrote: >  Is there a way to implement preemptive basic authentication with > Apache HttpClient 5.2 using a HttpRequestInterceptor similar to how > it's done here (accepted > response)<https://stackoverflow.com/questions/2014700/

Preemptive Basic auth with Apache HttpClient 5.2

2023-07-13 Thread D'Ascola, Giovanni
Is there a way to implement preemptive basic authentication with Apache HttpClient 5.2 using a HttpRequestInterceptor similar to how it's done here (accepted response)<https://stackoverflow.com/questions/2014700/preemptive-basic-authentication-with-apache-httpclient-4> for Apache HttpCl

Re: Httpclient issue with https "org.apache.hc.core5.http2.impl.nio.ClientH2StreamMultiplexer"

2023-05-12 Thread thc202
frame length and HC will reserve the whole chunk. (I also tried using a custom H2Config with smaller max frame length but it still allocates what the other endpoint advertises.) Hopefully this helps somehow. Best regards. Please configure HttpClient to use smaller (much smaller) max frame

Re: Httpclient issue with https "org.apache.hc.core5.http2.impl.nio.ClientH2StreamMultiplexer"

2023-05-12 Thread Oleg Kalnichevski
; > > growing > > > > past > > > > the max frame length in your local environment and propose a > > > > fix, > > > > which > > > > I can review and test locally. > > > > > > fwiw, I don't think it's growing past the max frame

Re: Httpclient issue with https "org.apache.hc.core5.http2.impl.nio.ClientH2StreamMultiplexer"

2023-05-12 Thread thc202
length but it still allocates what the other endpoint advertises.) Hopefully this helps somehow. Best regards. Please configure HttpClient to use smaller (much smaller) max frame length. I'm using: .setH2Config(H2Config.custom().setMaxFrameSize(MAX_FRAME_SIZE).build()) with MAX_FRAME_SIZE as 2MB

Re: Httpclient issue with https "org.apache.hc.core5.http2.impl.nio.ClientH2StreamMultiplexer"

2023-05-12 Thread Oleg Kalnichevski
> > fwiw, I don't think it's growing past the max frame length, it's at > the > max (16MB). > > I see this as well and my conclusion (which might be wrong) is that > HC > allocates the max immediately and it's kept that way for as long as > the > connection is open (whic

Re: Httpclient issue with https "org.apache.hc.core5.http2.impl.nio.ClientH2StreamMultiplexer"

2023-05-12 Thread thc202
regards. Oleg -Original Message- From: Oleg Kalnichevski Sent: Friday, May 12, 2023 9:47 AM To: HttpClient User Discussion Subject: Re: Httpclient issue with https "org.apache.hc.core5.http2.impl.nio.ClientH2StreamMultiplexer" On Thu, 2023-05-11 at 19:17 +0200, Joan grupove

Re: Httpclient issue with https "org.apache.hc.core5.http2.impl.nio.ClientH2StreamMultiplexer"

2023-05-12 Thread Oleg Kalnichevski
g forward: 1. You manage to reproduce the issue in an isolated environment that I can replicate locally (Docker image or a unit test).  2. You manage to find out the cause of FrameOutputBuffer growing past the max frame length in your local environment and propose a fix, which I can review a

RE: Httpclient issue with https "org.apache.hc.core5.http2.impl.nio.ClientH2StreamMultiplexer"

2023-05-12 Thread Joan grupoventus
://www.grupoventus.com/resources/https.png The point is that here traffic is very low, in production this traffic is much higher so the spike is about 20GB and the heap becomes exhausted. Joan. -Original Message- From: Oleg Kalnichevski Sent: Friday, May 12, 2023 9:47 AM To: HttpClient User Discussion

Re: Httpclient issue with https "org.apache.hc.core5.http2.impl.nio.ClientH2StreamMultiplexer"

2023-05-12 Thread Oleg Kalnichevski
will make the I/O reactor release intermediate TLS buffers which should substantially decrease the total memory footprint of TLS connections at the cost of extra memory allocation / de- allocation. Oleg - To unsubscribe, e-mail: httpclient-users-unsubscr...@hc.apache.org For additional commands, e-mail: httpclient-users-h...@hc.apache.org

Httpclient issue with https "org.apache.hc.core5.http2.impl.nio.ClientH2StreamMultiplexer"

2023-05-11 Thread Joan grupoventus
ion (logs about http traffic, etc). Thanks, Joan. - To unsubscribe, e-mail: httpclient-users-unsubscr...@hc.apache.org For additional commands, e-mail: httpclient-users-h...@hc.apache.org

Re: Questions for migration of httpclient-win to httpclient5-win

2023-03-13 Thread Sandeep Kulkarni
Hi, Based on an earlier comment from Oleg that WindowsCredentialsProvider class did nothing, I did some experiment with our existing code which still uses httpclient 4.5.x. Ours is a Dropwizard based application and we also make use of Jersey Client. I commented the code below which is used

Re: Questions for migration of httpclient-win to httpclient5-win

2023-03-12 Thread Gary Gregory
ication. > So > > please do consider keeping it supported for longer. > > > > Many people have started migrating from v4 or v4.5 of httpclient to v5 > > recently in the past 1-2 years. Enterprise softwares needs a longer > support > > timeframe. They will be facing

Re: Questions for migration of httpclient-win to httpclient5-win

2023-03-12 Thread Michael Osipov
-win entirely makes sense. It is used by many people like us who want to support Windows authentication. So please do consider keeping it supported for longer. Many people have started migrating from v4 or v4.5 of httpclient to v5 recently in the past 1-2 years. Enterprise softwares needs a longer

Re: Questions for migration of httpclient-win to httpclient5-win

2023-03-11 Thread Oleg Kalnichevski
d. > However, I don't think removing httpclient5-win entirely makes sense. > It is > used by many people like us who want to support Windows > authentication. So > please do consider keeping it supported for longer. > > Many people have started migrating from v4 or v4.5 of htt

Re: Questions for migration of httpclient-win to httpclient5-win

2023-03-11 Thread Sandeep Kulkarni
people like us who want to support Windows authentication. So please do consider keeping it supported for longer. Many people have started migrating from v4 or v4.5 of httpclient to v5 recently in the past 1-2 years. Enterprise softwares needs a longer support timeframe. They will be facing issues going

Re: Questions for migration of httpclient-win to httpclient5-win

2023-03-11 Thread Oleg Kalnichevski
On Fri, 2023-03-10 at 21:23 +0530, Sandeep Kulkarni wrote: > Hi, > > I am looking for a migration guide for httpclient-win to httpclient5- > win. I > could not find one at > https://hc.apache.org/httpcomponents-client-5.2.x/migration-guide/index.html > > Also I am

Questions for migration of httpclient-win to httpclient5-win

2023-03-10 Thread Sandeep Kulkarni
Hi, I am looking for a migration guide for httpclient-win to httpclient5-win. I could not find one at https://hc.apache.org/httpcomponents-client-5.2.x/migration-guide/index.html Also I am looking for any reason(s) for removal of WindowsCredentialsProvider from httpclient5-win. Our code uses

Re: Connection: Close header in response and Async HTTPClient api behaviour

2023-03-02 Thread sreenivas somavarapu
) { *outputStream.write(tmp, 0, l);* } } *HTTPClient has last line as below* 2023-03-02 21:53:52,710 DEBUG [org.apache.hc.client5.http.impl.async.HttpAsyncMainClientExec] ex-04: produce request data Another observation is even after connecting to a server, the request

Re: Connection: Close header in response and Async HTTPClient api behaviour

2023-02-24 Thread Oleg Kalnichevski
? Also is there a way to > suppress that ContentLength header with 0 value generation alone by > httpclient? > The problem is not HttpClient APIs but rather Servlet APIs which provide no reliable way of distinguishing requests with without a request entity from requests with z

Re: Connection: Close header in response and Async HTTPClient api behaviour

2023-02-23 Thread sreenivas somavarapu
by httpclient? Earlier in 4.x we had HttpEntityEnclosingRequestBase based on which we could determine what method accepts body and what method doesn't, but with 5.x (Both Synchronous and Asynchronous) I am unable to find any way. Regards, Sreenivas On Thu, Feb 23, 2023 at 2:31 AM Oleg Kalnichevski wrote

Re: Connection: Close header in response and Async HTTPClient api behaviour

2023-02-22 Thread Oleg Kalnichevski
onnection forcibly closed* in > case of > POST requests). If we don't add a request method check for skipping > adding > of entity to request, httpclient produces ContentLength header with 0 > (In > *RequestContent.java* process method there is a check for entity and > if > e

Re: Connection: Close header in response and Async HTTPClient api behaviour

2023-02-22 Thread sreenivas somavarapu
for skipping adding of entity to request, httpclient produces ContentLength header with 0 (In *RequestContent.java* process method there is a check for entity and if entity present it adds ContentLength header by default). Currently I see the only way to avoid not adding ContentLength header

Re: Connection: Close header in response and Async HTTPClient api behaviour

2023-02-22 Thread Oleg Kalnichevski
o add an entity to a request object or not. Is there > anything > similar methodology available for Async implementation or 5.x > httpclient > implementation as well through which we can determine for which > request > method instances we need to add entity objects to requestbuilder >

Re: Connection: Close header in response and Async HTTPClient api behaviour

2023-02-22 Thread sreenivas somavarapu
httpclient implementation as well through which we can determine for which request method instances we need to add entity objects to requestbuilder instead of the current hardcoded check for few methods? Regards, Sreenivas On Wed, Feb 22, 2023 at 2:38 AM Oleg Kalnichevski wrote: > On Wed, 2023-02

Re: Connection: Close header in response and Async HTTPClient api behaviour

2023-02-21 Thread Oleg Kalnichevski
On Wed, 2023-02-22 at 01:27 +0530, sreenivas somavarapu wrote: > Hi Team, > > > I have a perl script deployed on IIS server. When accessing this perl > script we are getting *Connection closed* error (see below for stack > trace) > from Async HTTPClient 5.2.x future c

Connection: Close header in response and Async HTTPClient api behaviour

2023-02-21 Thread sreenivas somavarapu
Hi Team, I have a perl script deployed on IIS server. When accessing this perl script we are getting *Connection closed* error (see below for stack trace) from Async HTTPClient 5.2.x future callback. When further debugged found that IIS is sending “Connection: Close” header after the response

Re: Regarding HTTP2 support for classic 5.x httpclient

2022-11-19 Thread Oleg Kalnichevski
On Sat, 2022-11-19 at 23:53 +0530, sreenivas somavarapu wrote: > Hi Oleg, > > How can we force to use a different protocols for different requests > using > same httpclient object is what I am looking for until now but was > unscuccessful in finding any examples or achiev

Re: Regarding HTTP2 support for classic 5.x httpclient

2022-11-19 Thread sreenivas somavarapu
Hi Oleg, How can we force to use a different protocols for different requests using same httpclient object is what I am looking for until now but was unscuccessful in finding any examples or achieving it using async httpclient implementation. Input request is not in my control. It could be from

Re: Regarding HTTP2 support for classic 5.x httpclient

2022-11-19 Thread Oleg Kalnichevski
tocol. My application gets > request > from users and my application should make sure that same protocol > should be > used as in request when getting the response from different servers > using > httpclient. So I was checking the feasibility in httpclient classic / > async &

Re: Regarding HTTP2 support for classic 5.x httpclient

2022-11-19 Thread sreenivas somavarapu
should be used as in request when getting the response from different servers using httpclient. So I was checking the feasibility in httpclient classic / async implementations to see if I could achieve that using same httpclient method. Regards, Sreenivas On Sat, Nov 19, 2022, 11:13 PM Oleg

Re: Regarding HTTP2 support for classic 5.x httpclient

2022-11-19 Thread Oleg Kalnichevski
On Sat, 2022-11-19 at 23:10 +0530, sreenivas somavarapu wrote: > Hi Oleg, > > Thank you for your reply.  > > My simple use case is I want to control on which channel / protocol > (HTTP 1.x or HTTP 2) the requests should use using async httpclient > api implementation ir

Re: Regarding HTTP2 support for classic 5.x httpclient

2022-11-19 Thread sreenivas somavarapu
Hi Oleg, Thank you for your reply. My simple use case is I want to control on which channel / protocol (HTTP 1.x or HTTP 2) the requests should use using async httpclient api implementation irrespective of backend server enablement of that respective protocol. Is there a way to achieve

Re: Regarding HTTP2 support for classic 5.x httpclient

2022-11-19 Thread Oleg Kalnichevski
all web app which will be used by users to > get > data from different servers. I am using httpclient here to get data > from > pre-configured servers which I even don't know before hand. Basically > kind > of reverse proxy. So if users request the data using HTTP 1.x I have > to ge

Re: Regarding HTTP2 support for classic 5.x httpclient

2022-11-18 Thread sreenivas somavarapu
with *Unsupported version* error. My usecase is I have a small web app which will be used by users to get data from different servers. I am using httpclient here to get data from pre-configured servers which I even don't know before hand. Basically kind of reverse proxy. So if users request

Re: Why NTLM is still supported by httpclient?

2022-11-10 Thread Yibo Liu
ities[1]. And a more secure > > authentication protocol Kerberos replaced NTLM as the default > > authentication tool on Windows 2000 and later releases[2]. > > > > My question is why does httpclient still implement NTLM instead of > > only providing the most preferred protocol - K

Re: Why NTLM is still supported by httpclient?

2022-11-10 Thread Michael Osipov
releases[2]. My question is why does httpclient still implement NTLM instead of only providing the most preferred protocol - Kerberos? Are there any other reasons besides backward compatibility? [1] https://learn.microsoft.com/en-us/openspecs/windows_protocols/ms-nlmp/1e846608-4c5f-41f4-8454

Why NTLM is still supported by httpclient?

2022-11-09 Thread Yibo Liu
httpclient still implement NTLM instead of only providing the most preferred protocol - Kerberos? Are there any other reasons besides backward compatibility? [1] https://learn.microsoft.com/en-us/openspecs/windows_protocols/ms-nlmp/1e846608-4c5f-41f4-8454-1b91af8a755b?redirectedfrom=MSDN [2] https

Re: Regarding HTTP2 support for classic 5.x httpclient

2022-11-06 Thread Gary Gregory
is perfectly > >>> adequate and works quite well for request / response oriented > >>> protocols > >>> such as HTTP/1.1. > >>> > >>> The HTTP/2 protocol is completely different. It is frame based and > >>> can > >>> mu

Re: Regarding HTTP2 support for classic 5.x httpclient

2022-11-06 Thread Michael Osipov
not work well with the classic I/O. Classic HttpClient 5.x implementation presently does not support HTTP/2 and most likely never will. If one needs HTTP/2 one has to switch to Async HttpClient 5.x. This also means that https://issues.apache.org/jira/browse/WAGON-606 would never happen unless

Re: Regarding HTTP2 support for classic 5.x httpclient

2022-11-05 Thread Tamás Cservenák
Please, forget Wagon (is Maven2 relic). Better do resolver-transport with http5 async instead :) T On Sat, Nov 5, 2022, 11:51 Oleg Kalnichevski wrote: > > Having said all that, how about this? I promise to build a HTTP/2 > implementation of Maven Wagon and contribute it to the Maven project

Re: Regarding HTTP2 support for classic 5.x httpclient

2022-11-05 Thread Oleg Kalnichevski
nge streams over the same physical > > connection. The message stream multiplexing just does not work well > > with the classic I/O. Classic HttpClient 5.x implementation > > presently > > does not support HTTP/2 and most likely never will. If one needs > > HTTP/2 >

Re: Regarding HTTP2 support for classic 5.x httpclient

2022-11-05 Thread Michael Osipov
Am 2022-11-04 um 12:59 schrieb Oleg Kalnichevski: On Fri, 2022-11-04 at 04:16 +0530, sreenivas somavarapu wrote: Hi Team, Might be the query had been answered before but I tried to search and was unscuccessful to find any reference stating whether Apache HTTPClient 5.x classic api

Re: Regarding HTTP2 support for classic 5.x httpclient

2022-11-04 Thread Oleg Kalnichevski
On Fri, 2022-11-04 at 04:16 +0530, sreenivas somavarapu wrote: > Hi Team, > > Might be the query had been answered before but I tried to search and > was > unscuccessful to find any reference stating whether Apache HTTPClient > 5.x > classic api implementation is suppo

Regarding HTTP2 support for classic 5.x httpclient

2022-11-03 Thread sreenivas somavarapu
Hi Team, Might be the query had been answered before but I tried to search and was unscuccessful to find any reference stating whether Apache HTTPClient 5.x classic api implementation is supporting HTTP 2 requests or not. I am trying to set request as HTTP 2 using below code but server

Re: Support for Multipart request in Async HTTPClient (5.x)

2022-10-20 Thread Oleg Kalnichevski
On Thu, 2022-10-20 at 14:02 +, vostinar laurian wrote: > Hi, > Any plans to add support for multi part request in Async HTTPClient ? > Currently, there is only MultipartEntityBuilder which is part of sync > HTTPClient and can only be used in async API if all the data is > l

Support for Multipart request in Async HTTPClient (5.x)

2022-10-20 Thread vostinar laurian
Hi, Any plans to add support for multi part request in Async HTTPClient ? Currently, there is only MultipartEntityBuilder which is part of sync HTTPClient and can only be used in async API if all the data is loaded in memory (which is not ideal). Anyone who has implemented a custom request

Re: HttpClient migration from 3.x to 5.x - Need info on support plan

2022-10-19 Thread Gary Gregory
0, Kaluva S wrote: > >> We are planning to migrate our old legacy code which uses > >> *commons-httpclient-3.x* to *httpclient5.x* . But found that its > >> going to > >> be complete rewrite as lot of classes/packages removed. > >> > >>

Re: HttpClient migration from 3.x to 5.x - Need info on support plan

2022-10-19 Thread Michael Osipov
Am 2022-10-18 um 17:27 schrieb Oleg Kalnichevski: On Tue, 2022-10-18 at 20:23 +0530, Kaluva S wrote: We are planning to migrate our old legacy code which uses *commons-httpclient-3.x* to *httpclient5.x* . But found that its going to be complete rewrite as lot of classes/packages removed. Tried

Re: HttpClient migration from 3.x to 5.x - Need info on support plan

2022-10-18 Thread Kaluva S
hich uses > > *commons-httpclient-3.x* to *httpclient5.x* . But found that its > > going to > > be complete rewrite as lot of classes/packages removed. > > > > Tried migrating to *httpclient4.x* , seems to be having lesser > > changes > > compared to *5.x* m

Re: HttpClient migration from 3.x to 5.x - Need info on support plan

2022-10-18 Thread Oleg Kalnichevski
On Tue, 2022-10-18 at 20:23 +0530, Kaluva S wrote: > We are planning to migrate our old legacy code which uses > *commons-httpclient-3.x* to *httpclient5.x* . But found that its > going to > be complete rewrite as lot of classes/packages removed. > > Tried migrating to *http

HttpClient migration from 3.x to 5.x - Need info on support plan

2022-10-18 Thread Kaluva S
We are planning to migrate our old legacy code which uses *commons-httpclient-3.x* to *httpclient5.x* . But found that its going to be complete rewrite as lot of classes/packages removed. Tried migrating to *httpclient4.x* , seems to be having lesser changes compared to *5.x* migration. But want

Re: Using httpclient 5.0.3 with httpcore 5.0.3

2021-04-06 Thread Oleg Kalnichevski
On 4/6/2021 12:27 AM, Maciej Walkowiak wrote: Hi, We use httpclient 5.0.3 as a dependency to our library. One of our library users run into an issue where http client run into possibly infinite loop and started consuming all available CPU. We are unfortunately not able to reproduce

Using httpclient 5.0.3 with httpcore 5.0.3

2021-04-06 Thread Maciej Walkowiak
Hi, We use httpclient 5.0.3 as a dependency to our library. One of our library users run into an issue where http client run into possibly infinite loop and started consuming all available CPU. We are unfortunately not able to reproduce it. httpclient 5.0.3 - the latest stable version - uses

[CVE-2020-13956] Apache HttpClient incorrect handling of malformed URI authority component

2020-10-08 Thread Oleg Kalnichevski
CVE-2020-13956: Apache HttpClient incorrect handling of malformed authority component in request URIs Severity: Medium Vendor: The Apache Software Foundation Versions Affected: Apache HttpClient 4.5.12 and prior Apache HttpClient 5.0.2 and prior Description: Apache HttpClient versions prior

Re: Task Cancelled by HttpClient - 4.1.4

2020-08-28 Thread SenthilKumar K
; I guess your problem is that you forget close the connection when > exception happened. > If so, you should put the close method in the finally block. > If connection doesn’t released, the connection pool will be fill up. > > 发件人: SenthilKumar K > 发送时间: 2020年8月28日 16:56 > 收件人

回复: Task Cancelled by HttpClient - 4.1.4

2020-08-28 Thread 樊超
: SenthilKumar K 发送时间: 2020年8月28日 16:56 收件人: httpclient-users@hc.apache.org 抄送: Senthil kumar 主题: Task Cancelled by HttpClient - 4.1.4 Hello Experts, We have been running Apache Async Http Client in Product to Post Events to Splunk & Datadog Third-Party Systems. Most of the times it works well but

Re: Task Cancelled by HttpClient - 4.1.4

2020-08-28 Thread Oleg Kalnichevski
ultConnectionConfig(connectionConfig > ) > .setConnectionManager(mgr) > .setSSLContext(getSSLContext()) > .setSSLHostnameVerifier(hostNameVerifier) > .disableConnectionState() &

Task Cancelled by HttpClient - 4.1.4

2020-08-28 Thread SenthilKumar K
leCookieManagement() .useSystemProperties(); CloseableHttpAsyncClient httpClient = httpClientBuilder.build(); httpClient.start(); org.apache.httpcomponents *httpasyncclient* 4.1.4 --Senthil

Re: Testing support for HttpClient.

2020-05-06 Thread Oleg Kalnichevski
part of a large and active project. You do not have to look at it if you do not feel like it. Obviously the code never got documented or updated since its initial contribution. Please also consider downside of your project no longer being independent. It will have to share the same release cycle

Re: Testing support for HttpClient.

2020-05-05 Thread Paweł Adamski
for it. Do you know if anything is available? Regards Paweł Adamski niedz., 3 maj 2020 o 17:42 Oleg Kalnichevski napisał(a): > On Sun, 2020-05-03 at 16:39 +0200, Paweł Adamski wrote: > > Hi > > My name is Paweł. I'm an author of the library for easy mocking > > H

Re: Testing support for HttpClient.

2020-05-03 Thread Oleg Kalnichevski
On Sun, 2020-05-03 at 16:39 +0200, Paweł Adamski wrote: > Hi > My name is Paweł. I'm an author of the library for easy mocking > HttpClient > ( https://github.com/PawelAdamski/HttpClientMock ). I would like to > ask > about your opinion wherever it would be a go

Testing support for HttpClient.

2020-05-03 Thread Paweł Adamski
Hi My name is Paweł. I'm an author of the library for easy mocking HttpClient ( https://github.com/PawelAdamski/HttpClientMock ). I would like to ask about your opinion wherever it would be a good idea to include it as an official library for testing code using HttpClient? I see that a lot

Unable to post to api with httpclient

2020-04-07 Thread amruta dale
Hi Team, I am getting error as per attached screenshot while posting request to api with httpclient. dependencies. avro-tools -1.8.2 http-client 4.5.12 kafka-client 2.3.0 kafka-avro-seralizer 5.3.0 Error: Exception in thread "main" java.lang.NoSuchFieldError

Re: How to post Kafka Avro records with httpclient

2020-04-06 Thread amruta dale
_ > Von: amruta dale > Gesendet: Monday, April 6, 2020 12:14:22 PM > An: httpclient-users@hc.apache.org > Betreff: How to post Kafka Avro records with httpclient > > Hi Team, > > I have written my own Producer interceptor in Java for Kafka Producer. >

Re: How to post Kafka Avro records with httpclient

2020-04-06 Thread Bernd Eckenfels
: Monday, April 6, 2020 12:14:22 PM An: httpclient-users@hc.apache.org Betreff: How to post Kafka Avro records with httpclient Hi Team, I have written my own Producer interceptor in Java for Kafka Producer. During intercepting I am trying to push avro message (record.value()) to one of the API via

How to post Kafka Avro records with httpclient

2020-04-06 Thread amruta dale
Hi Team, I have written my own Producer interceptor in Java for Kafka Producer. During intercepting I am trying to push avro message (record.value()) to one of the API via httpclient post method. I can send the simple messages to api however somehow for avro message I am unable to do so. Like

Re: httpclient

2020-03-23 Thread Tommy Pham
> I am a newbie to Java. > We are going to try Apache httpclient as an alternative for openjdk > httpsurl connection class. > > We see that using openjdk 8 and above we s eee that when using httpsurl > conenction we see a delay of 10 to 20 seconds to get content of the url. We &

Re: Possible bug in RedirectExec in HttpClient 5.0-beta7

2020-02-20 Thread Oleg Kalnichevski
35 +0100, Michael Osipov wrote: > > > > > Am 2020-02-18 um 10:07 schrieb Oleg Kalnichevski: > > > > > > On Mon, 2020-02-17 at 21:28 +0100, Michael Osipov wrote: > > > > > > > Folks, > > > > > > > > > > > > > >

Re: Possible bug in RedirectExec in HttpClient 5.0-beta7

2020-02-20 Thread Michael Osipov
+0100, Michael Osipov wrote: Folks, I have continued to fiddle a bit more with the redirector in HttpClient 5.0. I have modified my servlet code to respond with 307 from within a Tomcat valve which immediately kicks in after "Expect: 100- continue". There seems to be a bug in Re

Re: Possible bug in RedirectExec in HttpClient 5.0-beta7

2020-02-20 Thread Oleg Kalnichevski
28 +0100, Michael Osipov wrote: > > > > > Folks, > > > > > > > > > > I have continued to fiddle a bit more with the redirector in > > > > > HttpClient > > > > > 5.0. I have modified my servlet code to respond with 3

Re: Possible bug in RedirectExec in HttpClient 5.0-beta7

2020-02-19 Thread Michael Osipov
Am 2020-02-18 um 22:29 schrieb Oleg Kalnichevski: On Tue, 2020-02-18 at 20:35 +0100, Michael Osipov wrote: Am 2020-02-18 um 10:07 schrieb Oleg Kalnichevski: On Mon, 2020-02-17 at 21:28 +0100, Michael Osipov wrote: Folks, I have continued to fiddle a bit more with the redirector in HttpClient

Re: Possible bug in RedirectExec in HttpClient 5.0-beta7

2020-02-18 Thread Oleg Kalnichevski
On Tue, 2020-02-18 at 20:35 +0100, Michael Osipov wrote: > Am 2020-02-18 um 10:07 schrieb Oleg Kalnichevski: > > On Mon, 2020-02-17 at 21:28 +0100, Michael Osipov wrote: > > > Folks, > > > > > > I have continued to fiddle a bit more with the redirector i

Re: Possible bug in RedirectExec in HttpClient 5.0-beta7

2020-02-18 Thread Michael Osipov
Am 2020-02-18 um 10:07 schrieb Oleg Kalnichevski: On Mon, 2020-02-17 at 21:28 +0100, Michael Osipov wrote: Folks, I have continued to fiddle a bit more with the redirector in HttpClient 5.0. I have modified my servlet code to respond with 307 from within a Tomcat valve which immediately kicks

Re: Possible bug in RedirectExec in HttpClient 5.0-beta7

2020-02-18 Thread Oleg Kalnichevski
On Mon, 2020-02-17 at 21:28 +0100, Michael Osipov wrote: > Folks, > > I have continued to fiddle a bit more with the redirector in > HttpClient > 5.0. I have modified my servlet code to respond with 307 from within > a > Tomcat valve which immediately kicks in after

Possible bug in RedirectExec in HttpClient 5.0-beta7

2020-02-17 Thread Michael Osipov
Folks, I have continued to fiddle a bit more with the redirector in HttpClient 5.0. I have modified my servlet code to respond with 307 from within a Tomcat valve which immediately kicks in after "Expect: 100-continue". There seems to be a bug in RedirectExec: [m

Re: Log any remote request made by httpClient 4.5.x

2020-01-27 Thread Oleg Kalnichevski
gt; > On Mon, 2020-01-27 at 14:14 +0100, Tamás Cservenák wrote: > > > Howdy, > > > > > > I'd like to log ANY remote request httpClient 4.5.x does > > > (stable), > > > what is > > > the best way to active that? (like "upstream&

Re: Log any remote request made by httpClient 4.5.x

2020-01-27 Thread Tamás Cservenák
...also, I wanted to log ALL requests httpclient sends So ended up with a LoggingRequestExecutor, something like this: https://gist.github.com/cstamas/6a4165a64348490fa4fcdaa74757c966 but it looks to me like a hack. Also, unsure how to properly collect things I need (ie. in case of proxy etc

Re: Log any remote request made by httpClient 4.5.x

2020-01-27 Thread Tamás Cservenák
Tamás Cservenák wrote: > > Howdy, > > > > I'd like to log ANY remote request httpClient 4.5.x does (stable), > > what is > > the best way to active that? (like "upstream" request log, so method > > + URL > > [schema://hostname/path]). > > &g

Re: Log any remote request made by httpClient 4.5.x

2020-01-27 Thread Oleg Kalnichevski
On Mon, 2020-01-27 at 14:14 +0100, Tamás Cservenák wrote: > Howdy, > > I'd like to log ANY remote request httpClient 4.5.x does (stable), > what is > the best way to active that? (like "upstream" request log, so method > + URL > [schema://hostname/path]). > &

Log any remote request made by httpClient 4.5.x

2020-01-27 Thread Tamás Cservenák
Howdy, I'd like to log ANY remote request httpClient 4.5.x does (stable), what is the best way to active that? (like "upstream" request log, so method + URL [schema://hostname/path]). I'd like to cover cases even like httpClient CONNECT requests, httpClient retries (if configure

HttpCore / HttpClient 5.0 compatibility testing

2019-09-27 Thread Oleg Kalnichevski
Folks I have been testing HttpCore 5.0 and HttpClient 5.0 for compatibility with common HTTP servers such as Apache HTTPD and Ngnix for quite some time using Docker containers. I also recently added httpbin.org container to the list of target test environments. The image definitions can be found

RE: Way to send p12 file with post payload in httpclient 4.5.4

2019-09-26 Thread Khare, Aparna
Thanks it worked -Original Message- From: Bernd Eckenfels Sent: Thursday, September 26, 2019 12:45 PM To: HttpClient User Discussion Subject: Re: Way to send p12 file with post payload in httpclient 4.5.4 Maybe using a ByteArrayBody or FileBody should help, since the InputStream can

Re: Way to send p12 file with post payload in httpclient 4.5.4

2019-09-26 Thread Bernd Eckenfels
Maybe using a ByteArrayBody or FileBody should help, since the InputStream can be consumed only once. Gruss Bernd -- http://bernd.eckenfels.net Von: Khare, Aparna Gesendet: Donnerstag, September 26, 2019 9:03 AM An: HttpClient User Discussion Betreff: Way

Way to send p12 file with post payload in httpclient 4.5.4

2019-09-26 Thread Khare, Aparna
Dear All, Im using the below httpclient code to send the pk12 file Input stream is the stream obtained after reading pk12 file the same file is to be send to another endpoint MultipartEntity entity = new MultipartEntity(); entity.addPart("file", new InputStreamBody(inputStream2,

  1   2   3   4   5   6   7   8   9   10   >