schemeRegistry.register( new Scheme( "https", new EasySSLSocketFactory(), 443 ) );
HttpParams params = new BasicHttpParams();
// TODO put this values to a configuration way ???
params.setParameter( ConnManagerPNames.MAX_TOTAL_CONNECTIONS, 30 );
params.setParameter( ConnManagerPNames.MAX_CONNECTIONS_PER_ROUTE, new ConnPerRouteBean( 30 ) );
HttpProtocolParams.setVersion( params, HttpVersion.HTTP_1_1 );
ClientConnectionManager cm = new ThreadSafeClientConnManager( params, schemeRegistry );
httpClient = new DefaultHttpClient( cm, params );