Exemple #1
0
def getAll_http():
    proxies = ProxyManager('http').getAll()
    return proxies
Exemple #2
0
 def __init__(self, mode, queue, item_dict):
     ProxyManager.__init__(self, mode)
     Thread.__init__(self)
     self.log = LogHandler('proxy_check', file=False)  # 多线程同时写一个日志文件会有问题
     self.queue = queue
     self.item_dict = item_dict
Exemple #3
0
def get_http():
    proxy = ProxyManager('http').get_http()
    return proxy if proxy else 'no proxy!'
Exemple #4
0
 def __init__(self, mode):
     ProxyManager.__init__(self, mode)
     self.mode = mode
     self.queue = Queue()
     self.proxy_item = dict()
Exemple #5
0
 def __init__(self, mode):
     ProxyManager.__init__(self, mode)
     self.log = LogHandler('refresh_schedule')
Exemple #6
0
def getStatus_http():
    status = ProxyManager('http').getNumber()
    return status
Exemple #7
0
def delete_https():
    proxy = request.args.get('proxy')
    ProxyManager('https').delete(proxy)
    return 'success'