update_job_queue
¶
update_job_queue(
*,
config_overrides: Optional[BatchClientConfig] = None,
job_queue: Optional[String] = None,
state: Optional[JQState] = None,
scheduling_policy_arn: Optional[String] = None,
priority: Optional[Integer] = None,
compute_environment_order: Optional[ComputeEnvironmentOrders] = None,
service_environment_order: Optional[ServiceEnvironmentOrders] = None,
job_state_time_limit_actions: Optional[JobStateTimeLimitActions] = None,
) -> UpdateJobQueueResponse
Updates a job queue.
Parameters:
-
job_queue(Optional[String], default:None) –The name or the Amazon Resource Name (ARN) of the job queue.
-
state(Optional[JQState], default:None) –Describes the queue's ability to accept new jobs. If the job queue state is
ENABLED, it can accept jobs. If the job queue state isDISABLED, new jobs can't be added to the queue, but jobs already in the queue can finish. -
scheduling_policy_arn(Optional[String], default:None) –Amazon Resource Name (ARN) of the fair-share scheduling policy. Once a job queue is created, the fair-share scheduling policy can be replaced but not removed. The format is
aws:Partition:batch:Region:Account:scheduling-policy/Name. For example,aws:aws:batch:us-west-2:123456789012:scheduling-policy/MySchedulingPolicy. -
priority(Optional[Integer], default:None) –The priority of the job queue. Job queues with a higher priority (or a higher integer value for the
priorityparameter) are evaluated first when associated with the same compute environment. Priority is determined in descending order. For example, a job queue with a priority value of10is given scheduling preference over a job queue with a priority value of1. All of the compute environments must be either EC2 (EC2orSPOT) or Fargate (FARGATEorFARGATE_SPOT). EC2 and Fargate compute environments can't be mixed. -
compute_environment_order(Optional[ComputeEnvironmentOrders], default:None) –Details the set of compute environments mapped to a job queue and their order relative to each other. This is one of the parameters used by the job scheduler to determine which compute environment runs a given job. Compute environments must be in the
VALIDstate before you can associate them with a job queue. All of the compute environments must be either EC2 (EC2orSPOT) or Fargate (FARGATEorFARGATE_SPOT). EC2 and Fargate compute environments can't be mixed.All compute environments that are associated with a job queue must share the same architecture. Batch doesn't support mixing compute environment architecture types in a single job queue.
-
service_environment_order(Optional[ServiceEnvironmentOrders], default:None) –The order of the service environment associated with the job queue. Job queues with a higher priority are evaluated first when associated with the same service environment.
-
job_state_time_limit_actions(Optional[JobStateTimeLimitActions], default:None) –The set of actions that Batch perform on jobs that remain at the head of the job queue in the specified state longer than specified times. Batch will perform each action after
maxTimeSecondshas passed. (Note: The minimum value for maxTimeSeconds is 600 (10 minutes) and its maximum value is 86,400 (24 hours).)
Raises:
-
ClientException–These errors are usually caused by a client action. One example cause is using an action or resource on behalf of a user that doesn't have permissions to use the action or resource. Another cause is specifying an identifier that's not valid.
-
ServerException–These errors are usually caused by a server issue.
-
UnknownServiceError–The service returned an error code this client does not model.
Examples:
To update a job queue This example disables a job queue so that it can be deleted.
Source code in docs_src/capo_batch/_services/batch.py
3331 3332 3333 3334 3335 3336 3337 3338 3339 3340 3341 3342 3343 3344 3345 3346 3347 3348 3349 3350 3351 3352 3353 3354 3355 3356 3357 3358 3359 3360 3361 3362 3363 3364 3365 3366 3367 3368 3369 3370 3371 3372 3373 3374 3375 3376 3377 3378 3379 3380 3381 3382 3383 3384 3385 3386 3387 3388 3389 3390 3391 3392 3393 3394 3395 3396 3397 3398 3399 3400 3401 3402 3403 3404 3405 3406 3407 3408 3409 3410 3411 | |