You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Morning fellas, really loving working with gocron, it allows me to quickly schedule repeating tasks! :)
Im currently building a Prometheus Exporter and using the Monitor interface to measure task durations and add the results to a Prometheus Histogram. I would love to be able to also add whether a task was successful or not as a label to the metric.
I was wondering whether its possible to add the JobStatus to the RecordJobTiming function, similar as IncrementJob already has it in the Monitor interface.
I believe, we could pass the JobStatus, based on the error result when running e.callJobWithRecover(j) in:
@FalcoSuessgott I was thinking you could add another method to the interface RecordJobTimingWithStatus, but that's breaking as well. I'm good with adding it, just trying to think through the best way to roll it out as far as releases
Morning fellas, really loving working with
gocron
, it allows me to quickly schedule repeating tasks! :)Im currently building a Prometheus Exporter and using the
Monitor
interface to measure task durations and add the results to a Prometheus Histogram. I would love to be able to also add whether a task was successful or not as a label to the metric.I was wondering whether its possible to add the
JobStatus
to theRecordJobTiming
function, similar asIncrementJob
already has it in theMonitor
interface.I believe, we could pass the JobStatus, based on the error result when running
e.callJobWithRecover(j)
in:gocron/executor.go
Lines 399 to 408 in c84d8f7
Im aware, that this is probably a breaking change, but just wanted to get your thoughts on that one.
The text was updated successfully, but these errors were encountered: