Skip to content

Conversation

erdirowlands
Copy link
Contributor

@erdirowlands erdirowlands commented Oct 2, 2024

What

  • Http code 0 is returned by the typheous client for any uncategorised http errors. We should be able to assume most of the uncategorised attempts to connect to SaaS / Proxy are transient, and allow the SDK to retry. This PR adds 0 to the list of retryable codes.

  • -1 was being returned due to a bug in the OpenAPi generator, which meant the retryable codes were not being properly evaluated. This returns the code if it exists, or -1 if not

  • Adds an optional timeout_ms parameter to wait_for_initialized

Testing

Used local proxy tool to

  • return 0 for auth attempts. SDK retries
  • return 404 for auth attempts, SDk does not retry
  • supply timeout_ms argument and delay auth, the wait_for_initialization call unblocks and the SDK serves defaults

Copy link

@akiraqb akiraqb left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

some pretty cutting edge stuff!

@erdirowlands erdirowlands merged commit a7498e3 into main Oct 2, 2024
1 check passed
@erdirowlands erdirowlands deleted the FFM-12088 branch October 2, 2024 17:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants