From 3c6fced48e3efe2883646d53176af4073bbcca70 Mon Sep 17 00:00:00 2001 From: "yihua.huang" Date: Mon, 4 Nov 2013 00:53:01 +0800 Subject: [PATCH] update connection client --- .../java/us/codecraft/webmagic/downloader/HttpClientPool.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/webmagic-core/src/main/java/us/codecraft/webmagic/downloader/HttpClientPool.java b/webmagic-core/src/main/java/us/codecraft/webmagic/downloader/HttpClientPool.java index 62d87188..5c80ba5d 100644 --- a/webmagic-core/src/main/java/us/codecraft/webmagic/downloader/HttpClientPool.java +++ b/webmagic-core/src/main/java/us/codecraft/webmagic/downloader/HttpClientPool.java @@ -30,7 +30,7 @@ public class HttpClientPool { .register("http", PlainConnectionSocketFactory.INSTANCE) .register("https", SSLConnectionSocketFactory.getSocketFactory()) .build(); - PoolingHttpClientConnectionManager connectionManager = new PoolingHttpClientConnectionManager(reg); + connectionManager = new PoolingHttpClientConnectionManager(reg); connectionManager.setMaxTotal(poolSize); connectionManager.setDefaultMaxPerRoute(100); }