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

Oleg Kalnichevski commented on HTTPCLIENT-1292:
-----------------------------------------------

There will be a lot of changes in the next feature release (4.3). Among the 
most notable ones is the move towards relying more on object immutability 
rather than synchronization for thread safety. As of next release 
AbstractHttpClient, DefaultHttpClient,  AutoRetryHttpClient, 
DecompressingHttpClient and CachingHttpClient classes will be deprecated in 
favor of builders that produce immutable HttpClient instances. You can get a 
feel of the new API by looking at this sample aplication [1]. I could implement 
the feature you requested to the deprecated class but I doubt that makes a lot 
of sense.

If you do not object I'll close this issue as WONTFIX.

Oleg

[1] 
http://svn.apache.org/repos/asf/httpcomponents/httpclient/trunk/httpclient/src/examples/org/apache/http/examples/client/ClientConfiguration.java
                
> Get the embedded HttpClient from decorator HttpClient
> -----------------------------------------------------
>
>                 Key: HTTPCLIENT-1292
>                 URL: https://issues.apache.org/jira/browse/HTTPCLIENT-1292
>             Project: HttpComponents HttpClient
>          Issue Type: Improvement
>          Components: HttpClient
>    Affects Versions: 4.2.2
>            Reporter: Anthony Goubard
>              Labels: HttpClient, decorator, embedded
>   Original Estimate: 1h
>  Remaining Estimate: 1h
>
> If the developer gets a HttpClient thats extends AbstractHttpClient, he will 
> be able to add interceptor and call all the public get or set method of this 
> class.
> If the HttpClient is a decorator it's not possible to do all of this. The 
> reason is that you cannot get the embedded HttpClient from a decorator client.
> What would be nice, is to have an interface DecoratorClient with the method 
> getEmbeddedHttpClient()
> This interface would be implemented by AutoRetryHttpClient, 
> DecompressingHttpClient and CachingHttpClient.
> This way whenever you chain HttpClient you could still benefit from the 
> methods of AbstractHttpClient/DefaultHttpClient.
> Another possbility would be to have a getBaseHttpClient() and to have it 
> implemented with return this in AbstractHttpClient.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to