create_job
¶
create_job(
farm_id: FarmId,
queue_id: QueueId,
priority: JobPriority,
*,
config_overrides: Optional[deadlineClientConfig] = None,
client_token: Optional[ClientToken] = None,
template: Optional[JobTemplate] = None,
template_type: Optional[JobTemplateType] = None,
parameters: Optional[JobParameters] = None,
attachments: Optional[Attachments] = None,
storage_profile_id: Optional[StorageProfileId] = None,
target_task_run_status: Optional[CreateJobTargetTaskRunStatus] = None,
max_failed_tasks_count: Optional[MaxFailedTasksCount] = None,
max_retries_per_task: Optional[MaxRetriesPerTask] = None,
max_worker_count: Optional[MaxWorkerCount] = None,
source_job_id: Optional[JobId] = None,
name_override: Optional[JobName] = None,
description_override: Optional[JobDescriptionOverride] = None,
tags: Optional[Tags] = None,
) -> CreateJobResponse
Creates a job. A job is a set of instructions that Deadline Cloud uses to schedule and run work on available workers. For more information, see Deadline Cloud jobs.
Parameters:
-
farm_id(FarmId) –The farm ID of the farm to connect to the job.
-
queue_id(QueueId) –The ID of the queue that the job is submitted to.
-
client_token(Optional[ClientToken], default:None) –The unique token which the server uses to recognize retries of the same request.
-
template(Optional[JobTemplate], default:None) –The job template to use for this job.
-
template_type(Optional[JobTemplateType], default:None) –The file type for the job template.
-
priority(JobPriority) –The priority of the job. The highest priority (first scheduled) is 100. When two jobs have the same priority, the oldest job is scheduled first.
-
parameters(Optional[JobParameters], default:None) –The parameters for the job.
-
attachments(Optional[Attachments], default:None) –The attachments for the job. Attach files required for the job to run to a render job.
-
storage_profile_id(Optional[StorageProfileId], default:None) –The storage profile ID for the storage profile to connect to the job.
-
target_task_run_status(Optional[CreateJobTargetTaskRunStatus], default:None) –The initial job status when it is created. Jobs that are created with a
SUSPENDEDstatus will not run until manually requeued. -
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 each task.
-
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, Deadline Cloud won't throttle the number of workers used to process the job. -
source_job_id(Optional[JobId], default:None) –The job ID for the source job.
-
name_override(Optional[JobName], default:None) –A custom name to override the job name derived from the job template.
-
description_override(Optional[JobDescriptionOverride], default:None) –A custom description to override the job description derived from the job template.
-
tags(Optional[Tags], default:None) –The tags to add to your job. Each tag consists of a tag key and a tag value. Tag keys and values are both required, but tag values can be empty strings.
Raises:
-
AccessDeniedException–You don't have permission to perform the action.
-
InternalServerErrorException–Deadline Cloud can't process your request right now. Try again later.
-
ResourceNotFoundException–The requested resource can't be found.
-
ServiceQuotaExceededException–You exceeded your service quota. Service quotas, also referred to as limits, are the maximum number of service resources or operations for your Amazon Web Services account.
-
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/deadline.py
6972 6973 6974 6975 6976 6977 6978 6979 6980 6981 6982 6983 6984 6985 6986 6987 6988 6989 6990 6991 6992 6993 6994 6995 6996 6997 6998 6999 7000 7001 7002 7003 7004 7005 7006 7007 7008 7009 7010 7011 7012 7013 7014 7015 7016 7017 7018 7019 7020 7021 7022 7023 7024 7025 7026 7027 7028 7029 7030 7031 7032 7033 7034 7035 7036 7037 7038 7039 7040 7041 7042 7043 7044 7045 7046 7047 7048 7049 7050 7051 7052 7053 7054 7055 7056 7057 7058 7059 7060 7061 7062 7063 7064 7065 7066 7067 7068 7069 7070 7071 7072 7073 7074 7075 7076 7077 7078 7079 7080 7081 7082 7083 7084 7085 7086 7087 7088 7089 7090 7091 7092 7093 7094 7095 7096 7097 7098 7099 7100 7101 7102 7103 7104 | |