def __init__(self, account_id, num_connections=5): log.info('Creating connection pool for account {0} with {1}\ connections'.format(account_id, num_connections)) self.account_id = account_id self._set_account_info() # 1200s == 20min ConnectionPool.__init__(self, num_connections, keepalive=1200)
def __init__(self, account_id, num_connections, readonly): log.info('Creating Crispin connection pool for account {} with {} ' 'connections'.format(account_id, num_connections)) self.account_id = account_id self.readonly = readonly self._set_account_info() # 1200s == 20min ConnectionPool.__init__(self, num_connections, keepalive=1200)
def __init__(self, account_id, num_connections, debug=False): self.log = get_logger(account_id, 'sendmail: connection_pool') self.log.info('Creating SMTP connection pool for account {0} with {1} ' 'connections'.format(account_id, num_connections)) self.account_id = account_id self._set_account_info() self.debug = debug # 1200s == 20min ConnectionPool.__init__(self, num_connections, keepalive=1200)
def __init__(self, account_id, num_connections=5, debug=False): self.log = get_logger(account_id, 'sendmail: connection_pool') self.log.info('Creating SMTP connection pool for account {0} with {1} ' 'connections'.format(account_id, num_connections)) self.account_id = account_id self._set_account_info() self.debug = debug self.auth_handlers = {'OAuth': self.smtp_oauth, 'Password': self.smtp_password} # 1200s == 20min ConnectionPool.__init__(self, num_connections, keepalive=1200)
def __init__(self, service, region='us-east-1'): ConnectionPool.__init__(self, 10) self.service = service self.region = region
def __init__(self, pool_size, server, version, redis_timeout): ConnectionPool.__init__(self, pool_size, keepalive=redis_timeout/2) self.server = server self.version = version
def __init__(self, pool_size, server, max_max_query_time, socket_timeout): ConnectionPool.__init__(self, pool_size, keepalive=socket_timeout/2) self.server = server self.max_max_query_time = max_max_query_time self.socket_timeout = socket_timeout