Beispiel #1
0
 private static synchronized void kill() {
   if (sessionList != null) {
     for (HTTPSession session : sessionList) {
       session.close();
     }
     sessionList.clear();
     // Rebuild the connection manager
     connmgr.shutdown();
     connmgr = new MultiThreadedHttpConnectionManager();
     setGlobalThreadCount(DFALTTHREADCOUNT);
   }
 }
Beispiel #2
0
  static {
    connmgr = new MultiThreadedHttpConnectionManager();
    setGlobalThreadCount(DFALTTHREADCOUNT);
    registry = new ArrayList<ProtocolEntry>();
    // Fill in the registry for our various https ports
    // allow self-signed certificates
    registerProtocol(
        "https", 0, new Protocol("https", new EasySSLProtocolSocketFactory(), 443)); // default
    registerProtocol(
        "https",
        8443,
        new Protocol("https", new EasySSLProtocolSocketFactory(), 8443)); // std tomcat https entry

    setGlobalConnectionTimeout(DFALTTIMEOUT);
    setGlobalSoTimeout(DFALTTIMEOUT);
    getGlobalProxyD(); // get info from -D if possible
    setGlobalKeyStore();
  }
Beispiel #3
0
 // Alias
 public static void setGlobalMaxConnections(int nthreads) {
   setGlobalThreadCount(nthreads);
 }