go-sundheit
go-sundheit copied to clipboard
Allow for one-shot cheks
Nice little package :-)
In my experience, it's fairly common to expose alongside the health check values some static information about the service, typically the version.
Problem is, the only way to expose those information with go-sundheit
is to define a check which means having a ticker refreshing the value. A ticker is not a performance issue but it's still a bit silly. It would be nice if go-sundheit
allowed to do that in a less hacky way.
It could be as simple as allowing to set ExecutionPeriod
to zero and not starting the ticker.
@MichaelMure This is indeed a simple change, but I will make this change only if you think a one-shot check is valuable as a check.
I'm saying that cause think using a health checks library to expose static data feels like a mix of concerns
WDYT?