Improve the observability of the init container #1149
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Why are these changes needed?
The current version presents a challenge for users troubleshooting issues related to the init container, mainly due to the absence of logs from this container. Typically, error messages from the health check are suppressed because, if the GCS server is not ready, these messages can erroneously suggest a problem, which could lead to user confusion.
This Pull Request addresses these concerns by:
Only If the initialization process exceeds 120 seconds, will the init container produces logs.
If the prolonged initialization is not caused by any real error but caused by heavy commands executed before the 'ray start' in the head pod, then once GSC server is ready, a log message will inform the users that any preceding 'Connection Refused' error messages can be safely ignored. This message should help users discern between genuine errors and the normal output during a slow startup.
Checks