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

Add docker health checks #87

Open
aaron97neu opened this issue Oct 1, 2020 · 2 comments
Open

Add docker health checks #87

aaron97neu opened this issue Oct 1, 2020 · 2 comments
Assignees
Labels
enhancement New feature or request
Milestone

Comments

@aaron97neu
Copy link
Member

As part of our writing out tests, we should integrate health checks to our Dockerfiles
https://docs.docker.com/engine/reference/builder/#healthcheck

An example of a good health check for gps2tsdb would be a python script that gets the most recent gps point in the postgres db and ensures that it is no more than 5s old

@aaron97neu aaron97neu added the enhancement New feature or request label Oct 1, 2020
@aaron97neu aaron97neu added this to the 0.1.1 Testing milestone Oct 1, 2020
@aaron97neu
Copy link
Member Author

Once #103 is merged, we will have gps, cell and can loggers with health checks. This leaves can_watchdog, oada_upload, and socketcand. Unsure if we can or want to do socketcand since it is developed by someone else.

@abalmos @facastiblancor what are your thoughts on how to check can_watchdog and oada_upload on a conceptual level?
can_watchdog does not modify anything so measuring it's effects would be hard
oada_upload would also be interesting. You could check to see if the sent column changed recently but then you would be settingoada_upload as unhealthy if it does not have internet and isn't uploading stuff even if it is otherwise working fine. Maybe combine that with an internet check? Issue then is that it could be broken but you would never know if you are not connected to the internet. Is oada_upload conceptually unhealthy if it does not have internet?

@aaron97neu aaron97neu self-assigned this Oct 9, 2020
@facastiblancor
Copy link
Collaborator

@aaron97neu I think socketcand does not need a health check. It will be eventually phased out by other messaging systems in the future. But if we wanted to do a health check, it would be to check the program is running and the desired CAN interfaces are exposed. In my opinion, it would be better to implement this check in the apps using socketcand. For can_watchdog I think we don't need to check its health status. If it fails, then it will keep restarting. That way we know something is wrong with it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants