[prev in list] [next in list] [prev in thread] [next in thread]
List: httpclient-users
Subject: Re: maxPerRoute -- what *exactly* defines a route?
From: Oleg Kalnichevski <olegk () apache ! org>
Date: 2017-11-02 13:46:53
Message-ID: 1509630413.20807.9.camel () apache ! org
[Download RAW message or body]
On Wed, 2017-11-01 at 23:34 -0600, Shawn Heisey wrote:
> One of the settings that you can set when creating HttpClient objects
> is
> the maximum connections per route on the connection
> manager. Increasing
> this value is part of making HttpClient capable of handling many
> threads/connections at once.
>
> The exact definition of a route is not stated in the javadoc for the
> builder class, and I haven't been able to find it anywhere else
> either.
>
> I did find this SO post, but I don't see an answer there that's
> clear.
> The HttpRoute javadoc may contain the answer, but if it does, it's
> not
> straightforward.
>
> https://stackoverflow.com/questions/12028635/what-is-the-meaning-of-p
> er-route-basis-in-poolingclientconnectionmanager
>
> A section of documentation from an entirely different project
> (nodejs)
> was given. A different project may have a very different definition
> of
> a route than THIS project.
>
> So I'm looking for what the definition of a route is for
> httpcomponents,
> and would like to see that information added to the javadoc on the
> Builder class(es) and the connection manager class(es).
>
Connection routing is described here
http://hc.apache.org/httpcomponents-client-4.5.x/tutorial/html/connmgmt
.html#d5e351
Essentially, an HTTP route represents an address of the target host
along with an optional list of addresses of intermediate proxies (or
hops)
An address is either DNS + port or IP + port.
client -> target (direct route)
client -> proxy -> target (route by proxy)
client -> proxy (tunnel) -> target (tunneled route)
client -> proxy1 (tunnel) -> proxy2 (tunnel) -> target
(complex tunneled route)
> If I were to open an issue for this, would it go on HTTPCLIENT or
> HTTPCORE? Should I open an issue?
>
It should go on HTTPCLIENT. Please do feel to submit improvements by
all of means.
Oleg
> I suspect that the definition of a route is probably the
> "protocol://host:port" combination, and based on the info about
> nodejs
> that was given, may also include the type of request
> (GET/POST/HEAD/OPTIONS/etc). It might only take the host into
> account
> and ignore the protocol and port. It might have more information,
> such
> as a defined proxy server, authentication parameters, etc. Can
> anyone
> confirm or deny? If the host is involved, I would also need to know
> whether it is compared as given, or if any conversion (lowercasing,
> IP
> address resolution, finding FQDN, etc.) happens before comparison.
>
> If a detailed answer to this question is in a FAQ somewhere, perhaps
> that should be referenced by javadoc and in other places.
>
> Thanks,
> Shawn
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: httpclient-users-unsubscribe@hc.apache.org
> For additional commands, e-mail: httpclient-users-help@hc.apache.org
>
---------------------------------------------------------------------
To unsubscribe, e-mail: httpclient-users-unsubscribe@hc.apache.org
For additional commands, e-mail: httpclient-users-help@hc.apache.org
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic