예제 #1
0
 def start(self, threads=5):
     pl = []
     for i in range(threads):
         pl.append(ProxyCheck())
     for i in pl:
         i.deamon = True
         i.start()
     for i in pl:
         i.join()
예제 #2
0
    def __validProxy(self, threads=20):
        # 验证useful_proxy代理
        thread_list = list()
        for index in range(threads):
            thread_list.append(ProxyCheck(self.queue, self.proxy_item))

        for thread in thread_list:
            thread.daemon = True
            thread.start()

        for thread in thread_list:
            thread.join()
예제 #3
0
    def __validProxy(self, threads=5):
        """
        验证useful_proxy代理
        :param threads: 线程数
        :return:
        """
        thread_list = list()
        for index in range(threads):
            thread_list.append(ProxyCheck())

        for thread in thread_list:
            thread.start()

        for thread in thread_list:
            thread.join()
    def __validProxy(self, threads=10):
        """
        验证useful_proxy代理
        :param threads: 线程数
        :return:
        """
        thread_list = list()
        for index in range(threads):
            thread_list.append(ProxyCheck(self.queue, self.proxy_item))

        for thread in thread_list:
            thread.daemon = True
            thread.start()

        for thread in thread_list:
            thread.join()