Skip to content
New issue

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

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

Already on GitHub? # to your account

fix(runner): Remove setInterval from providers reload #3057

Merged
merged 7 commits into from
Nov 25, 2024

Conversation

nalanj
Copy link
Contributor

@nalanj nalanj commented Nov 25, 2024

setInterval can cause problems because it doesn't ensure that multiple callbacks don't run at the same time. This removes setInterval from provider reloading.

Note: I'm not sure if it's worth it in this case to deploy runners or just wait until we deploy them next time.

See https://linear.app/nango/issue/NAN-2245/fix-do-not-use-setinterval

How I tested it:

  • Make sure a runner has started
  • Edit the providers.yaml
  • Wait for the reloadInterval (60s by default) to ensure you get a message that it was updated

@nalanj nalanj self-assigned this Nov 25, 2024
@nalanj nalanj changed the title Remove setInterval from providers reload fix(runner): Remove setInterval from providers reload Nov 25, 2024
@nalanj nalanj marked this pull request as ready for review November 25, 2024 17:00
@nalanj nalanj requested a review from a team November 25, 2024 17:00
@nalanj nalanj enabled auto-merge (squash) November 25, 2024 19:16
@nalanj nalanj merged commit 3d6744a into master Nov 25, 2024
19 checks passed
@nalanj nalanj deleted the alan/providers-refresh-no-interval branch November 25, 2024 19:25
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants