def get_http_handler(self, scraper_config):
    '\n        Get http handler for a specific scraper config.\n        The http handler is cached using `prometheus_url` as key.\n        '
    prometheus_url = scraper_config['prometheus_url']
    if (prometheus_url in self._http_handlers):
        return self._http_handlers[prometheus_url]
    if (scraper_config['ssl_ca_cert'] is False):
        scraper_config['ssl_verify'] = False
    if (scraper_config['ssl_verify'] is False):
        scraper_config.setdefault('tls_ignore_warning', True)
    http_handler = self._http_handlers[prometheus_url] = RequestsWrapper(scraper_config, self.init_config, self.HTTP_CONFIG_REMAPPER, self.log)
    headers = http_handler.options['headers']
    bearer_token = scraper_config['_bearer_token']
    if (bearer_token is not None):
        headers['Authorization'] = 'Bearer {}'.format(bearer_token)
    headers.setdefault('accept-encoding', 'gzip')
    headers.setdefault('accept', 'text/plain')
    return http_handler
Get http handler for a specific scraper config.
The http handler is cached using `prometheus_url` as key.
def get_http_handler(self, scraper_config):
    '\n        Get http handler for a specific scraper config.\n        The http handler is cached using `prometheus_url` as key.\n        '
    prometheus_url = scraper_config['prometheus_url']
    if (prometheus_url in self._http_handlers):
        return self._http_handlers[prometheus_url]
    if (scraper_config['ssl_ca_cert'] is False):
        scraper_config['ssl_verify'] = False
    if (scraper_config['ssl_verify'] is False):
        scraper_config.setdefault('tls_ignore_warning', True)
    http_handler = self._http_handlers[prometheus_url] = RequestsWrapper(scraper_config, self.init_config, self.HTTP_CONFIG_REMAPPER, self.log)
    headers = http_handler.options['headers']
    bearer_token = scraper_config['_bearer_token']
    if (bearer_token is not None):
        headers['Authorization'] = 'Bearer {}'.format(bearer_token)
    headers.setdefault('accept-encoding', 'gzip')
    headers.setdefault('accept', 'text/plain')
    return http_handler