Пример #1
0
    def client_run(self, conn, addr):
        ""
        if self.config['GENERAL']['PARENT_PROXY']:
            # working with MS Proxy
            c = proxy_client.proxy_HTTP_Client(conn, addr, self.config)
        else:
            # working with MS IIS and any other
            c = www_client.www_HTTP_Client(conn, addr, self.config)

        thread.start_new_thread(c.run, ())
Пример #2
0
 def client_run(self, conn, addr):
     if self.config["GENERAL"]["PARENT_PROXY"]:
         # working with MS Proxy
         if self.watchUpstream:
             # Locking here is really more of a 'nice to have';
             # if performance suffers on heavy load we can trade
             # drops here for drops on bad proxy later.
             self.monLock.acquire()
             c = proxy_client.proxy_HTTP_Client(conn, addr, self.config)
             self.monitor.threadsToKill.append(c)
             self.monLock.release()
         else:
             c = proxy_client.proxy_HTTP_Client(conn, addr, self.config)
     else:
         # working with MS IIS and any other
         c = www_client.www_HTTP_Client(conn, addr, self.config)
     thread.start_new_thread(c.run, ())
Пример #3
0
 def client_run(self, conn, addr):
     if self.config['GENERAL']['PARENT_PROXY']:
         # working with MS Proxy
         if self.watchUpstream:
             # Locking here is really more of a 'nice to have';
             # if performance suffers on heavy load we can trade
             # drops here for drops on bad proxy later.
             self.monLock.acquire()
             c = proxy_client.proxy_HTTP_Client(conn, addr, self.config)
             self.monitor.threadsToKill.append(c)
             self.monLock.release()
         else:
             c = proxy_client.proxy_HTTP_Client(conn, addr, self.config)
     else:
         # working with MS IIS and any other
         c = www_client.www_HTTP_Client(conn, addr, self.config)
     thread.start_new_thread(c.run, ())