<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def get_http_json(self, url=None, retry_count=3, rate_limit_timeout=120, headers=None):
 """ The function for retrieving a json result via HTTP. Args: url (:obj:`str`):
 The URL to retrieve (required). retry_count (:obj:`int`):
 The number of times to retry in case socket errors, timeouts, connection resets, etc. are encountered. Defaults to 3. rate_limit_timeout (:obj:`int`):
 The number of seconds to wait before retrying when a rate limit notice is returned via rdap+json or HTTP error 429. Defaults to 60. headers (:obj:`dict`):
 The HTTP headers. The Accept header defaults to 'application/rdap+json'. Returns: dict: The data in json format. Raises: HTTPLookupError: The HTTP lookup failed. HTTPRateLimitError: The HTTP request rate limited and retries were exhausted. """


        if headers is None:
            headers = {'Accept': 'application/rdap+json'}

        try:

            # Create the connection for the whois query.
            log.debug('HTTP query for {0} at {1}'.format(
                self.address_str, url))
            conn = Request(url, headers=headers)
            data = self.opener.open(conn, timeout=self.timeout)
            try:
                d = json.loads(data.readall().decode('utf-8', 'ignore'))
            except AttributeError:  # pragma: no cover
                d = json.loads(data.read().decode('utf-8', 'ignore'))

            try:
                # Tests written but commented out. I do not want to send a
                # flood of requests on every test.
                for tmp in d['notices']:  # pragma: no cover
                    if tmp['title'] == 'Rate Limit Notice':
                        log.debug('RDAP query rate limit exceeded.')

                        if retry_count > 0:
                            log.debug('Waiting {0} seconds...'.format(
                                str(rate_limit_timeout)))

                            sleep(rate_limit_timeout)
                            return self.get_http_json(
                                url=url, retry_count=retry_count-1,
                                rate_limit_timeout=rate_limit_timeout,
                                headers=headers
                            )
                        else:
                            raise HTTPRateLimitError(
                                'HTTP lookup failed for {0}. Rate limit '
                                'exceeded, wait and try again (possibly a '
                                'temporary block).'.format(url))

            except (KeyError, IndexError):  # pragma: no cover

                pass

            return d

        except HTTPError as e:  # pragma: no cover

            # RIPE is producing this HTTP error rather than a JSON error.
            if e.code == 429:

                log.debug('HTTP query rate limit exceeded.')

                if retry_count > 0:
                    log.debug('Waiting {0} seconds...'.format(
                        str(rate_limit_timeout)))

                    sleep(rate_limit_timeout)
                    return self.get_http_json(
                        url=url, retry_count=retry_count - 1,
                        rate_limit_timeout=rate_limit_timeout,
                        headers=headers
                    )
                else:
                    raise HTTPRateLimitError(
                        'HTTP lookup failed for {0}. Rate limit '
                        'exceeded, wait and try again (possibly a '
                        'temporary block).'.format(url))

            else:

                raise HTTPLookupError('HTTP lookup failed for {0} with error '
                                      'code {1}.'.format(url, str(e.code)))

        except (URLError, socket.timeout, socket.error) as e:

            log.debug('HTTP query socket error: {0}'.format(e))
            if retry_count > 0:

                log.debug('HTTP query retrying (count: {0})'.format(
                    str(retry_count)))

                return self.get_http_json(
                    url=url, retry_count=retry_count-1,
                    rate_limit_timeout=rate_limit_timeout, headers=headers
                )

            else:

                raise HTTPLookupError('HTTP lookup failed for {0}.'.format(
                    url))

        except (HTTPLookupError, HTTPRateLimitError) as e:  # pragma: no cover

            raise e

        except:  # pragma: no cover

            raise HTTPLookupError('HTTP lookup failed for {0}.'.format(url))