Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix: Avoid error when sending double API calls (SOFIE-3242) #17

Merged
merged 3 commits into from
Jun 24, 2024

Conversation

nytamin
Copy link
Collaborator

@nytamin nytamin commented Jun 20, 2024

About the Contributor

This pull request is posted on behalf of the NRK.

Type of Contribution

This is a:

Bug fix

Current Behavior

If I send two restart-calls in quick succession, the first restart call will throw with a ABORTED (-3) error, which will set the status to an Error, which doesnt look good.

New Behavior

All API calls are now put in a queue and executed in order. Multiple calls will now work properly.

Testing Instructions

Other Information

Status

  • PR is ready to be reviewed.
  • The functionality has been tested by the author.
  • Relevant unit tests has been added / updated.
  • Relevant documentation (code comments, system documentation) has been added / updated.

This fixes an issue where multiple calls (eg to restart() ) would cause calls to throw with ABORTED (-3) errors, which didn't look good in the status.
@nytamin nytamin requested a review from a team June 20, 2024 08:26
@nytamin nytamin merged commit 1d807b9 into main Jun 24, 2024
2 checks passed
@nytamin nytamin deleted the fix/api-race-conditions branch June 24, 2024 06:54
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