Skip to main content

job_queues

Creates, updates, deletes or gets a job_queue resource or lists job_queues in a region

Overview

Namejob_queues
TypeResource
DescriptionResource Type definition for AWS::Batch::JobQueue
Idawscc.batch.job_queues

Fields

NameDatatypeDescription
job_queue_namestring
job_queue_arnstringARN of the Scheduling Policy.
job_queue_typestring
compute_environment_orderarray
service_environment_orderarray
job_state_time_limit_actionsarray
priorityinteger
statestring
tagsobjectA key-value pair to associate with a resource.
regionstringAWS region.

For more information, see AWS::Batch::JobQueue.

Methods

NameResourceAccessible byRequired Params
create_resourcejob_queuesINSERTPriority, region
delete_resourcejob_queuesDELETEIdentifier, region
update_resourcejob_queuesUPDATEIdentifier, PatchDocument, region
list_resourcesjob_queues_list_onlySELECTregion
get_resourcejob_queuesSELECTIdentifier, region

SELECT examples

Gets all properties from an individual job_queue.

SELECT
region,
job_queue_name,
job_queue_arn,
job_queue_type,
compute_environment_order,
service_environment_order,
job_state_time_limit_actions,
priority,
state,
scheduling_policy_arn,
tags
FROM awscc.batch.job_queues
WHERE
region = '{{ region }}' AND
Identifier = '{{ job_queue_arn }}';

INSERT example

Use the following StackQL query and manifest file to create a new job_queue resource, using stack-deploy.

/*+ create */
INSERT INTO awscc.batch.job_queues (
Priority,
region
)
SELECT
'{{ priority }}',
'{{ region }}'
RETURNING
ErrorCode,
EventTime,
Identifier,
Operation,
OperationStatus,
RequestToken,
ResourceModel,
RetryAfter,
StatusMessage,
TypeName
;

UPDATE example

Use the following StackQL query and manifest file to update a job_queue resource, using stack-deploy.

/*+ update */
UPDATE awscc.batch.job_queues
SET PatchDocument = string('{{ {
"ComputeEnvironmentOrder": compute_environment_order,
"ServiceEnvironmentOrder": service_environment_order,
"JobStateTimeLimitActions": job_state_time_limit_actions,
"Priority": priority,
"State": state,
"SchedulingPolicyArn": scheduling_policy_arn
} | generate_patch_document }}')
WHERE
region = '{{ region }}' AND
Identifier = '{{ job_queue_arn }}'
RETURNING
ErrorCode,
EventTime,
Identifier,
Operation,
OperationStatus,
RequestToken,
ResourceModel,
RetryAfter,
StatusMessage,
TypeName
;

DELETE example

/*+ delete */
DELETE FROM awscc.batch.job_queues
WHERE
Identifier = '{{ job_queue_arn }}' AND
region = '{{ region }}'
RETURNING
ErrorCode,
EventTime,
Identifier,
Operation,
OperationStatus,
RequestToken,
ResourceModel,
RetryAfter,
StatusMessage,
TypeName
;

Additional Parameters

Mutable resources in the Cloud Control provider support additional optional parameters which can be supplied with INSERT, UPDATE, or DELETE operations. These include:

ParameterDescription
ClientToken
A unique identifier to ensure the idempotency of the resource request.This allows the provider to accurately distinguish between retries and new requests.
A client token is valid for 36 hours once used.
After that, a resource request with the same client token is treated as a new request.
If you do not specify a client token, one is generated for inclusion in the request.
RoleArn
The ARN of the IAM role used to perform this resource operation.The role specified must have the permissions required for this operation.
If you do not specify a role, a temporary session is created using your AWS user credentials.
TypeVersionId
For private resource types, the type version to use in this resource operation.If you do not specify a resource version, the default version is used.

Permissions

To operate on the job_queues resource, the following permissions are required:

Batch:CreateJobQueue,
Batch:TagResource,
Batch:DescribeJobQueues