hc-httpclient-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From arcivanov <arca...@ivanov.biz>
Subject Re: Proxy chaining
Date Mon, 16 Jun 2014 18:32:52 GMT
Oleg Kalnichevski wrote
> On Sun, 2014-06-15 at 18:24 -0700, arcivanov wrote:
>> Hi Oleg,
>> 
>> RequestDirector and respectively DefaultRequestDirector have been
>> deprecated
>> as of 4.3 with no replacement suggested/provided. 
> 
> That bit of logic got moved to MainClientExec
> 
> http://hc.apache.org/httpcomponents-client-4.3.x/httpclient/xref/org/apache/http/impl/execchain/MainClientExec.html#346

Thanks a lot, that's what I thought, however I'm somewhat lost looking at
how to extend this class, without actually trying to branch the
HttpComponents, but rather introducing a new proxy provider behavior. My
problem is as follows:

* MainClientExec.establishRoute is package-private, so I would have to place
my overriding components in impl.execchain and I'd have to create bundle
patches given that I'm using OSGI.
* MainClientExec.createTunnelToProxy is private and cannot be overwritten at
all
* MainClientExec is hard-instantiated in
http://hc.apache.org/httpcomponents-client-4.3.x/httpclient/xref/org/apache/http/impl/client/HttpClientBuilder.html#787
- it's not a pluggable service. I could override
HttpClientBuilder.decorateMainExec and created some decorator ClientExec but
for that I would need to copy all the logic from the MainClientExec related
to route handling and delegate the rest - seems quite cumbersome and would
require quite a lot of validation testing.

Am I missing something major?

Thanks for your help!

- Arcadiy



--
View this message in context: http://httpcomponents.10934.n7.nabble.com/Proxy-chaining-tp19965p23630.html
Sent from the HttpClient-User mailing list archive at Nabble.com.

---------------------------------------------------------------------
To unsubscribe, e-mail: httpclient-users-unsubscribe@hc.apache.org
For additional commands, e-mail: httpclient-users-help@hc.apache.org


Mime
View raw message