Skip to content
This repository was archived by the owner on Jul 22, 2021. It is now read-only.
This repository was archived by the owner on Jul 22, 2021. It is now read-only.

max_retries #60

Description

@askreet

In many places in the PHP SDK max_retries is compared using the <= operator, resulting in a max_retries of 0 meaning "retry once". I found this comparison in 5+ source files, here is the example I hit:

    # (Line 948 sdk.class.php)

    if ($this->redirects <= $this->max_retries)
    {
        // Exponential backoff
        $delay = (integer) (pow(4, $this->redirects) * 100000);
        usleep($delay);
        $this->redirects++;
        $data = $this->authenticate($operation, $original_payload);
    }

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions