AWS Thinkbox Discussion Forums

Help with modifying "job history" with script?

Hey guys. I have a few simple job scripts that do the following:

  1. Change priority
  2. Change machine limit
  3. Send email notification

I noticed that if a user modifies their own job, Deadline does a great job at logging that activity in the job’s history. However, when using the deadline commands, it doesn’t get logged. I was wondering if someone could point me in the right direction for putting this activity into the job history. Here’s an example snippet from one of these simple scripts.

for job in jobs:
    job.JobPriority = priority
    ## Log the above change in the job history
    RepositoryUtils.SaveJob(job)
    maxHosts = job.JobTaskCount
    jobIdentity = job.ID
    RepositoryUtils.SetMachineLimitMaximum(jobIdentity , maxHosts)
    ## Log the above change in the job history

There currently isn’t a script API hook to log history entries, so we’re going to have to add that in. I imagine it should be pretty straightforward to do so, so we’ll see if we can squeeze it into 6.1.

Thanks for bringing this oversight to our attention!

Cheers,
Ryan

Privacy | Site terms | Cookie preferences