Don’t forget to set defaultMaxPerRoute when using Apache Httpclient’s PoolingHttpClientConnectionManager

Don’t forget set defaultMaxPerRoute when using Apache Httpclient’s PoolingHttpClientConnectionManager .  Otherwise only very few http clients will be created.

For example,

PoolingHttpClientConnectionManager cm = new PoolingHttpClientConnectionManager();
cm.setDefaultMaxPerRoute(1000);

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.