-
Notifications
You must be signed in to change notification settings - Fork 9
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
Healthchecks provided for all context storages #279
Conversation
The two forms are equivalent but our usage of them was inconsistent (some containers had string commands; others -- cmd-shell). I think this form looks better; could change all commands to `CMD-SHELL` if needed.
interval: 5s | ||
timeout: 10s | ||
retries: 5 | ||
start_period: 30s |
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.
Could you explain how these numbers were chosen?
If we used the default ones we wouldn't have to specify anything and have
healthcheck:
test: mysql -u $${MYSQL_USERNAME} -p$${MYSQL_PASSWORD} -e "select 1;"
psql:
instead.
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.
These numbers were chosen after local testing; some DB images already have healthchecks included, other do not.
I wanted all of them to be in equal conditions.
timeout: 10s | ||
retries: 5 | ||
start_period: 30s | ||
|
||
dashboard: |
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.
Do we need health checks for dashboard
and otelcol
?
AFAIK dashboard performs its own health checks that are unrelated to docker.
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.
We can, but I am not very familiar with what properties should we test in that cases. If you have a suggestion - I'll research how to add some.
compose.yml
Outdated
@@ -41,6 +63,13 @@ services: | |||
- 27017:27017 | |||
volumes: | |||
- mongo-data:/data/db | |||
healthcheck: | |||
test: ["CMD-SHELL", "mongosh --norc --quiet --eval 'db.runCommand(\"ping\").ok' localhost:27017/test"] |
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.
Now mongo
spams docker logs every 5 seconds with
mongo-1 | {"t":{"$date":"2023-11-21T00:43:27.123+00:00"},"s":"I", "c":"NETWORK", "id":22943, "ctx":"listener","msg":"Connection accepted","attr":{"remote":"127.0.0.1:38256","uuid":"3b900426-57ec-4b36-80d3-cbcd0ec55cbe","connectionId":51,"connectionCount":3}}
mongo-1 | {"t":{"$date":"2023-11-21T00:43:27.124+00:00"},"s":"I", "c":"NETWORK", "id":51800, "ctx":"conn50","msg":"client metadata","attr":{"remote":"127.0.0.1:38248","client":"conn50","doc":{"application":{"name":"mongosh 1.10.0"},"driver":{"name":"nodejs|mongosh","version":"5.6.0|1.10.0"},"platform":"Node.js v16.20.0, LE","os":{"name":"linux","architecture":"x64","version":"6.6.1-arch1-1","type":"Linux"}}}}
mongo-1 | {"t":{"$date":"2023-11-21T00:43:27.124+00:00"},"s":"I", "c":"NETWORK", "id":51800, "ctx":"conn51","msg":"client metadata","attr":{"remote":"127.0.0.1:38256","client":"conn51","doc":{"application":{"name":"mongosh 1.10.0"},"driver":{"name":"nodejs|mongosh","version":"5.6.0|1.10.0"},"platform":"Node.js v16.20.0, LE","os":{"name":"linux","architecture":"x64","version":"6.6.1-arch1-1","type":"Linux"}}}}
mongo-1 | {"t":{"$date":"2023-11-21T00:43:27.127+00:00"},"s":"I", "c":"NETWORK", "id":22943, "ctx":"listener","msg":"Connection accepted","attr":{"remote":"127.0.0.1:38264","uuid":"19309746-b63b-42a1-baa3-83ee8ed8b244","connectionId":52,"connectionCount":4}}
mongo-1 | {"t":{"$date":"2023-11-21T00:43:27.127+00:00"},"s":"I", "c":"NETWORK", "id":51800, "ctx":"conn52","msg":"client metadata","attr":{"remote":"127.0.0.1:38264","client":"conn52","doc":{"application":{"name":"mongosh 1.10.0"},"driver":{"name":"nodejs|mongosh","version":"5.6.0|1.10.0"},"platform":"Node.js v16.20.0, LE","os":{"name":"linux","architecture":"x64","version":"6.6.1-arch1-1","type":"Linux"}}}}
mongo-1 | {"t":{"$date":"2023-11-21T00:43:27.257+00:00"},"s":"I", "c":"NETWORK", "id":22944, "ctx":"conn51","msg":"Connection ended","attr":{"remote":"127.0.0.1:38256","uuid":"3b900426-57ec-4b36-80d3-cbcd0ec55cbe","connectionId":51,"connectionCount":3}}
mongo-1 | {"t":{"$date":"2023-11-21T00:43:27.257+00:00"},"s":"I", "c":"NETWORK", "id":22944, "ctx":"conn50","msg":"Connection ended","attr":{"remote":"127.0.0.1:38248","uuid":"272ddbb7-be66-4f8a-ad36-3895ee6c01a2","connectionId":50,"connectionCount":0}}
mongo-1 | {"t":{"$date":"2023-11-21T00:43:27.257+00:00"},"s":"I", "c":"NETWORK", "id":22944, "ctx":"conn52","msg":"Connection ended","attr":{"remote":"127.0.0.1:38264","uuid":"19309746-b63b-42a1-baa3-83ee8ed8b244","connectionId":52,"connectionCount":2}}
mongo-1 | {"t":{"$date":"2023-11-21T00:43:27.257+00:00"},"s":"I", "c":"NETWORK", "id":22944, "ctx":"conn49","msg":"Connection ended","attr":{"remote":"127.0.0.1:38240","uuid":"e1760d4a-303b-40a7-a279-d87747596239","connectionId":49,"connectionCount":1}}
Could we do something about that?
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.
This is not really posible: we can not disable logging for 1 command only.
# Release Notes - Fix attachment sending via Telegram interfaces (81673b5) - Fix PollingTelegramInterface dropping whenever an error occurred while responding (ec19921) - Fix `Pipeline._run_pipeline` failing when `ctx_id=None` (5c22cc7) - Docker improvements (#279) - Various tutorial improvements - Add release checklist
Description
Also make command
wait_db
was removed and replaced with--wait
flag (it will be also valid for #132).Also
docker-compose
commands renamed todocker compose
+ file renamed (as it is preferred now).Checklist
To Consider
.ignore
files, scripts (such aslint
), distribution manifest (if files are added/deleted)