hc-httpclient-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Oleg Kalnichevski <ol...@apache.org>
Subject Re: SSL Session caching and connection pooling
Date Thu, 01 Nov 2012 10:20:40 GMT
On Wed, Oct 31, 2012 at 05:02:39PM -0700, John Sheehy wrote:
> Hi all,
> 
> if there are any Android users out there, does anyone know if there is
> a need to explicitly provide an SSL session cache with HttpClient 4.2
> in order to avoid TLS negotiation with every new TCP connection ?
> 
> I've got a repackaged 4.2 (some 4.0.x version is built-into android
> and that hogs the org.apache namespace, hence the repackaging), and
> I'm finding it very difficult to get the connection/context logs to be
> visible.
> 
> Something like the following perhaps?
> 
> 
> SSLSessionCache sessionCache = new SSLSessionCache(context);
> 
> schemeRegistry.register(new Scheme("https",
>         SSLCertificateSocketFactory.getHttpSocketFactory(
>         SOCKET_OPERATION_TIMEOUT, sessionCache), 443));
> 
> 
> Thanks,
> 
> John.
> 

John

Do you know if SSL connections get re-used for consecutive requests or new connection gets
created for each individual request? You might want to fix the connection re-use problem first,
if the latter is the case.

Oleg


> ---------------------------------------------------------------------
> 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


Mime
View raw message