Skip to content

returning false unless success? obscures response errors and transient ones should be retried in backoff method #580

@ericcj

Description

@ericcj

@iloveitaly we're thinking of patching this but wanted some feedback first. actions like search and get_list use a pattern of "if success? else return false" where success is typically defined as response_hash[:status][:@is_success] == 'true' but we find transient errors in both the above methods so suspect they are 5xx that should be retried. since the response isn't returned we haven't actually captured one.

Proposal:

  • add a raise_on_failed_response option to NetSuite.configure that raises Netsuite::FailedResponseError < StandardError which includes a response accessor
  • retry these for now from backoff, ideally identify only the transient ones to retry in the future

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