-
Notifications
You must be signed in to change notification settings - Fork 17
MLE-21148 Add Retry for Group Config #321
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
base: release/2.1.0
Are you sure you want to change the base?
Conversation
Pipeline is failing. Please review. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR introduces a retry mechanism for group configuration to increase the robustness of the configuration process.
- Added a new retry() helper function to encapsulate retry logic.
- Replaced direct configure_group calls with retry wrappers to attempt group configuration up to 5 times.
- Added explicit return codes on failure paths in group configuration.
@@ -176,6 +174,22 @@ data: | |||
echo $message >> /tmp/script.log | |||
} | |||
|
|||
retry() { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[nitpick] Consider adding a comment above the retry function to explain its parameters and behavior, which would help maintainers quickly understand its purpose.
Copilot uses AI. Check for mistakes.
return $exit_code | ||
fi | ||
echo "Attempt $count failed. Retrying..." | ||
sleep 5 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[nitpick] Consider making the retry delay configurable instead of hard-coding a 5-second sleep to allow easier adjustments in different environments.
sleep 5 | |
sleep ${RETRY_DELAY:-5} |
Copilot uses AI. Check for mistakes.
dfde5bf
to
6e2d9a8
Compare
No description provided.