Skip to content

Instantly share code, notes, and snippets.

@olympum
olympum / BigPipeContinuationServlet.java
Created July 14, 2010 05:38
BigPipeContinuationServlet
public class BigPipeContinuationServlet extends HttpServlet {
private HttpClient httpClient;
@Override
public void init() throws ServletException {
httpClient = new HttpClient();
httpClient.setConnectorType(HttpClient.CONNECTOR_SELECT_CHANNEL);
httpClient.setMaxConnectionsPerAddress(200); // max 200 concurrent connections to every address
httpClient.setThreadPool(new QueuedThreadPool(250)); // max 250 threads