update_job
async
¶
update_job(
farm_id: FarmId,
queue_id: QueueId,
job_id: JobId,
*,
config_overrides: Optional[AsyncdeadlineClientConfig] = None,
client_token: Optional[ClientToken] = None,
target_task_run_status: Optional[JobTargetTaskRunStatus] = None,
priority: Optional[JobPriority] = None,
max_failed_tasks_count: Optional[MaxFailedTasksCount] = None,
max_retries_per_task: Optional[MaxRetriesPerTask] = None,
lifecycle_status: Optional[UpdateJobLifecycleStatus] = None,
max_worker_count: Optional[MaxWorkerCount] = None,
name: Optional[JobName] = None,
description: Optional[JobDescriptionOverride] = None,
) -> UpdateJobResponse
Updates a job.
When you change the status of the job to ARCHIVED, the job can't be scheduled or archived.
An archived jobs and its steps and tasks are deleted after 120 days. The job can't be recovered.
Parameters:
-
farm_id(FarmId) –The farm ID of the job to update.
-
queue_id(QueueId) –The queue ID of the job to update.
-
job_id(JobId) –The job ID to update.
-
client_token(Optional[ClientToken], default:None) –The unique token which the server uses to recognize retries of the same request.
-
target_task_run_status(Optional[JobTargetTaskRunStatus], default:None) –The task status to update the job's tasks to.
-
priority(Optional[JobPriority], default:None) –The updated job priority.
-
max_failed_tasks_count(Optional[MaxFailedTasksCount], default:None) –The number of task failures before the job stops running and is marked as
FAILED. -
max_retries_per_task(Optional[MaxRetriesPerTask], default:None) –The maximum number of retries for a job.
-
lifecycle_status(Optional[UpdateJobLifecycleStatus], default:None) –The status of a job in its lifecycle. When you change the status of the job to
ARCHIVED, the job can't be scheduled or archived.An archived jobs and its steps and tasks are deleted after 120 days. The job can't be recovered.
-
max_worker_count(Optional[MaxWorkerCount], default:None) –The maximum number of worker hosts that can concurrently process a job. When the
maxWorkerCountis reached, no more workers will be assigned to process the job, even if the fleets assigned to the job's queue has available workers.You can't set the
maxWorkerCountto 0. If you set it to -1, there is no maximum number of workers.If you don't specify the
maxWorkerCount, the default is -1.The maximum number of workers that can process tasks in the job.
-
name(Optional[JobName], default:None) –The updated job name.
-
description(Optional[JobDescriptionOverride], default:None) –The updated job description.
Raises:
-
AccessDeniedException–You don't have permission to perform the action.
-
ConflictException–Your request has conflicting operations. This can occur if you're trying to perform more than one operation on the same resource at the same time.
-
InternalServerErrorException–Deadline Cloud can't process your request right now. Try again later.
-
ResourceNotFoundException–The requested resource can't be found.
-
ThrottlingException–Your request exceeded a request rate quota.
-
ValidationException–The request isn't valid. This can occur if your request contains malformed JSON or unsupported characters.
-
UnknownServiceError–The service returned an error code this client does not model.
Source code in docs_src/capo_deadline/_services/async_deadline.py
7265 7266 7267 7268 7269 7270 7271 7272 7273 7274 7275 7276 7277 7278 7279 7280 7281 7282 7283 7284 7285 7286 7287 7288 7289 7290 7291 7292 7293 7294 7295 7296 7297 7298 7299 7300 7301 7302 7303 7304 7305 7306 7307 7308 7309 7310 7311 7312 7313 7314 7315 7316 7317 7318 7319 7320 7321 7322 7323 7324 7325 7326 7327 7328 7329 7330 7331 7332 7333 7334 7335 7336 7337 7338 7339 7340 7341 7342 7343 7344 7345 7346 7347 7348 7349 7350 7351 7352 7353 7354 7355 7356 7357 7358 7359 7360 7361 7362 7363 7364 7365 7366 7367 7368 7369 7370 7371 7372 7373 7374 7375 7376 | |