-
Notifications
You must be signed in to change notification settings - Fork 375
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
[O11y][SQL Input] Add healthcheck to all images #9861
[O11y][SQL Input] Add healthcheck to all images #9861
Conversation
/test |
interval: 1s | ||
retries: 90 |
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.
Running healthcheck every second (in case it is failing) is just too much unnecessary overhead.
Probably these are more sane defaults:
interval: 10s
timeout: <decide some sane default>
retries: 5
start_period: <decide some sane default>
If Postgres container on averages takes time to start up, let's set a start_period
. If this healthcheck command using sqlcmd is quick, probably setting a small timeout is good. I think interval 5/10s and retries 5/10 should be more than enough.
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.
Yes. Setting interval
and retries
to values like 5/10 would make sense. But since the container does not take a lot time to start I think we can skip start_period
and timeout
IMO. Similar config was there in microsoft_sqlserver
package but it's good to keep some proper values in retries and interval.
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.
I know. Many healthchecks are improper in our packages.
USER root | ||
ENV MYSQL_ROOT_PASSWORD test | ||
|
||
HEALTHCHECK --interval=1s --retries=90 CMD /healthcheck.sh |
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.
Let's set better defaults. Retrying after every 1s is never good.
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.
LGTM
… into fix_sql_input_tests
/test |
💚 Build Succeeded
History
|
Quality Gate passedIssues Measures |
Proposed commit message
Fixes the flaky tests which result in error message
one or more errors found in documents stored in metrics-sql.sql-ep data stream: [0] found error.message in event: cannot open connection: testing connection: dial tcp 172.18.0.7:3306: connect: connection refused
Checklist
changelog
as this change doesn't relate to the changes that should be visible at user's endHow to test this PR locally
Related issues
Screenshots