I am working on a monitoring tool where in I have to monitor the job completion and calculate the estimates in accordance.
Till now I have kind of been able to capture the start and endtime of the jobs as below and have written them to a file as job_monitor.csv. I do this search repeatedly evey two minutes and append the relevant jobs.
Once the above details are captured, I am looking to convert this into a below format. There could be jobs with same JOBNAME, but two jobs cannot run in parallel, ie , if there is an entry for start_time , then the next End_time is relevant to the same job itself. I am not able to map these to look as below.
Any guidance would be appreciated. Thank You in Advance to all here.
Any specific reason to do it like this, instead of suggesting to use the transaction command?
Especially since he states that job names can be re-used (but not in parallel), using transactions may give more accurate results than using stats values()..., right?
stats is any time better than transaction command I gave this solution considering performance. I think even this would give accurate results as long as there is a unique start_time and end_time for a specific jobname
because I could see from the table there are only two records for a specific jobname.
Just to add on , there cuuld be a situation where in the job has started and has not completed, In that case I would need the record as below
which would let me know that the job has started but not completed yet. thanks again.