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(executor): Retry kubectl on internal transient error #8092

Merged
merged 3 commits into from
Mar 8, 2022

Conversation

wujayway
Copy link
Contributor

@wujayway wujayway commented Mar 7, 2022

fix(executor): Retry kubectl on internal transient error
Signed-off-by: wujayway [email protected]

Fixes fix(executor): Retry kubectl on internal transient error

This PR(#6472, #6467) only fix retry kubectl on k8s api error.
We also need to retry kubectl on internal transient error.

fix(executor): Retry kubectl on internal transient error
Signed-off-by: wujayway <[email protected]>
@wujayway
Copy link
Contributor Author

wujayway commented Mar 7, 2022

cc @terrytangyuan

Comment on lines +81 to +87
func generateErrorString(err error) string {
errorString := err.Error()
if exitErr, ok := err.(*exec.ExitError); ok {
errorString = fmt.Sprintf("%s %s", errorString, exitErr.Stderr)
}
return errorString
}
Copy link
Member

Choose a reason for hiding this comment

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

Could you add some tests?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

ok

add ut
Signed-off-by: wujayway <[email protected]>
add ut
Signed-off-by: wujayway <[email protected]>
@wujayway wujayway marked this pull request as ready for review March 8, 2022 10:48
@terrytangyuan terrytangyuan merged commit 765333d into argoproj:master Mar 8, 2022
@wujayway wujayway deleted the transienterror branch March 8, 2022 15:51
@sarabala1979 sarabala1979 mentioned this pull request Mar 18, 2022
12 tasks
alexec pushed a commit that referenced this pull request Mar 18, 2022
* fix(executor): Retry kubectl on internal transient error

fix(executor): Retry kubectl on internal transient error
Signed-off-by: wujayway <[email protected]>

* add ut

add ut
Signed-off-by: wujayway <[email protected]>

* add ut

add ut
Signed-off-by: wujayway <[email protected]>
sarabala1979 pushed a commit that referenced this pull request Mar 18, 2022
* fix(executor): Retry kubectl on internal transient error

fix(executor): Retry kubectl on internal transient error
Signed-off-by: wujayway <[email protected]>

* add ut

add ut
Signed-off-by: wujayway <[email protected]>

* add ut

add ut
Signed-off-by: wujayway <[email protected]>
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.

None yet

3 participants