I am running a jobs with a kubernetes POD and I need to measure the execution time for each job .
I want to get it through some api.
Does anyone know how can I get it ?
A job has a property denominated status
of type JobStatus.
The properties which you are looking for in the JobStatus
type is the startTime
and the completionTime
, which as the name suggest are responsible for indicating the moment where the job started/completed. The difference between these values is going to lead you to the duration of the execution of the job.