def submit(self, definition): """ Name ---- `scheduler.jobs.submit` (`definition`) Description ----------- Submit the given job data which is in LAVA job JSON or YAML format as a new job to LAVA scheduler. Arguments --------- `definition`: string Job JSON or YAML string. Return value ------------ This function returns an XML-RPC integer which is the newly created job's id, provided the user is authenticated with an username and token. If the job is a multinode job, this function returns the list of created job IDs. """ cls = SchedulerAPI(self._context) return cls.submit_job(definition)
def cancel(self, job_id): """ Name ---- `scheduler.jobs.cancel` (`job_id`) Description ----------- Cancel the given job referred by its id. Arguments --------- `job_id`: string Job id which should be canceled. Return value ------------ None. The user should be authenticated with an username and token. """ cls = SchedulerAPI(self._context) return cls.cancel_job(job_id)
def resubmit(self, job_id): """ Name ---- `scheduler.jobs.resubmit` (`job_id`) Description ----------- Resubmit the given job referred by its id. Arguments --------- `job_id`: string The job's id which should be re-submitted. Return value ------------ This function returns an XML-RPC integer which is the newly created job's id, provided the user is authenticated with an username and token. """ cls = SchedulerAPI(self._context) return cls.resubmit_job(job_id)