Skip to content

Add retries gem and catch common network errors #53

@benjaminjackson

Description

@benjaminjackson

We should be wrapping all network calls to Fauna in a retries block like this:

with_retries(:max_tries => 3, :rescue => [Timeout::Error, Errno::ECONNRESET, Fauna::Connection::NetworkError], :max_sleep_seconds => 10) do
    self.client.post params
end

https://github.com/ooyala/retries

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions