create_job
async
¶
create_job(
farm_id: FarmId,
queue_id: QueueId,
priority: JobPriority,
*,
config_overrides: Optional[AsyncdeadlineClientConfig] = 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/async_deadline.py
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 7105 7106 7107 7108 7109 7110 7111 7112 7113 7114 7115 7116 7117 7118 7119 7120 7121 7122 7123 7124 7125 7126 7127 7128 7129 7130 7131 7132 7133 7134 7135 7136 7137 7138 7139 7140 7141 7142 7143 7144 7145 7146 7147 7148 7149 7150 7151 7152 7153 7154 7155 7156 7157 7158 7159 7160 7161 7162 7163 7164 7165 7166 7167 7168 7169 7170 7171 7172 7173 7174 7175 7176 7177 7178 7179 7180 7181 7182 7183 7184 7185 7186 7187 7188 7189 7190 7191 7192 7193 7194 7195 7196 7197 7198 7199 7200 | |