public function hasExceededRetries($retries)
    {
        $delay = $this->getDelay($retries, false);

        return (
            (!$this->max_retries && ($delay >= $this->max_backoff)) ||
            ($this->max_retries && ($retries > $this->max_retries))
        );

    }