Skip to content

Fix delay in retryable execution - #102

Open
weiiwang01 wants to merge 2 commits into
charmed-kubernetes:mainfrom
weiiwang01:main
Open

Fix delay in retryable execution#102
weiiwang01 wants to merge 2 commits into
charmed-kubernetes:mainfrom
weiiwang01:main

Conversation

@weiiwang01

Copy link
Copy Markdown
Contributor

There's a bug in ts-retry that causes lastDelay in DelayParameters not to be populated.

franckLdx/ts-retry#41

This causes the actions-operator to retry immediately instead of using backoff, which creates problems in some workflows related to Snap, for example: https://github.com/canonical/nginx-ingress-integrator-operator/actions/runs/21815422114/job/63059385120?pr=316

In this pull request, currentTry of DelayParameters is used to construct the backoff delay to bypass this problem. And the default maxTry is also increased to 6, as the original value of 5 results in 1 initial try and 4 retries, which seems to contradict the retry delays described in the comment.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

1 participant