Skip to content

create_queue

create_queue(
    *,
    config_overrides: Optional[MediaConvertClientConfig] = None,
    concurrent_jobs: Optional[__integer] = None,
    description: Optional[__string] = None,
    maximum_concurrent_feeds: Optional[__integerMin0] = None,
    name: Optional[__string] = None,
    pricing_plan: Optional[PricingPlan] = None,
    reservation_plan_settings: Optional[ReservationPlanSettings] = None,
    status: Optional[QueueStatus] = None,
    tags: Optional[__mapOf__string] = None,
) -> CreateQueueResponse

Create a new transcoding queue. For information about queues, see Working With Queues in the User Guide at https://docs.aws.amazon.com/mediaconvert/latest/ug/working-with-queues.html

Parameters:

  • concurrent_jobs (Optional[__integer], default: None ) –

    Specify the maximum number of jobs your queue can process concurrently. For on-demand queues, the value you enter is constrained by your service quotas for Maximum concurrent jobs, per on-demand queue and Maximum concurrent jobs, per account. For reserved queues, specify the number of jobs you can process concurrently in your reservation plan instead.

  • description (Optional[__string], default: None ) –

    Optional. A description of the queue that you are creating.

  • maximum_concurrent_feeds (Optional[__integerMin0], default: None ) –

    Specify the maximum number of Elemental Inference feeds MediaConvert can process concurrently.

  • name (Optional[__string], default: None ) –

    The name of the queue that you are creating.

  • pricing_plan (Optional[PricingPlan], default: None ) –

    Specifies whether the pricing plan for the queue is on-demand or reserved. For on-demand, you pay per minute, billed in increments of .01 minute. For reserved, you pay for the transcoding capacity of the entire queue, regardless of how much or how little you use it. Reserved pricing requires a 12-month commitment. When you use the API to create a queue, the default is on-demand.

  • reservation_plan_settings (Optional[ReservationPlanSettings], default: None ) –

    Details about the pricing plan for your reserved queue. Required for reserved queues and not applicable to on-demand queues.

  • status (Optional[QueueStatus], default: None ) –

    Initial state of the queue. If you create a paused queue, then jobs in that queue won't begin.

  • tags (Optional[__mapOf__string], default: None ) –

    The tags that you want to add to the resource. You can tag resources with a key-value pair or with only a key.

Raises:

  • BadRequestException –

    The service can't process your request because of a problem in the request. Please check your request form and syntax.

  • ConflictException –

    The service couldn't complete your request because there is a conflict with the current state of the resource.

  • ForbiddenException –

    You don't have permissions for this action with the credentials you sent.

  • InternalServerErrorException –

    The service encountered an unexpected condition and can't fulfill your request.

  • NotFoundException –

    The resource you requested doesn't exist.

  • ServiceQuotaExceededException –

    You attempted to create more resources than the service allows based on service quotas.

  • TooManyRequestsException –

    Too many requests have been sent in too short of a time. The service limits the rate at which it will accept requests.

  • UnknownServiceError –

    The service returned an error code this client does not model.

Source code in docs_src/capo_mediaconvert/_services/media_convert.py
def create_queue(
    self,
    *,
    config_overrides: Optional[MediaConvertClientConfig] = None,
    concurrent_jobs: Optional["capo_mediaconvert.types.__integer.__integer"] = None,
    description: Optional["capo_mediaconvert.types.__string.__string"] = None,
    maximum_concurrent_feeds: Optional[
        "capo_mediaconvert.types.__integer_min0.__integerMin0"
    ] = None,
    name: Optional["capo_mediaconvert.types.__string.__string"] = None,
    pricing_plan: Optional[
        "capo_mediaconvert.types.pricing_plan.PricingPlan"
    ] = None,
    reservation_plan_settings: Optional[
        "capo_mediaconvert.types.reservation_plan_settings.ReservationPlanSettings"
    ] = None,
    status: Optional["capo_mediaconvert.types.queue_status.QueueStatus"] = None,
    tags: Optional[
        "capo_mediaconvert.types.__map_of__string.__mapOf__string"
    ] = None,
) -> "capo_mediaconvert.types.create_queue_response.CreateQueueResponse":
    """Create a new transcoding queue. For information about queues, see Working With Queues in the User Guide at https://docs.aws.amazon.com/mediaconvert/latest/ug/working-with-queues.html

    Args:
        concurrent_jobs: Specify the maximum number of jobs your queue can process concurrently. For on-demand queues, the value you enter is constrained by your service quotas for Maximum concurrent jobs, per on-demand queue and Maximum concurrent jobs, per account. For reserved queues, specify the number of jobs you can process concurrently in your reservation plan instead.
        description: Optional. A description of the queue that you are creating.
        maximum_concurrent_feeds: Specify the maximum number of Elemental Inference feeds MediaConvert can process concurrently.
        name: The name of the queue that you are creating.
        pricing_plan: Specifies whether the pricing plan for the queue is on-demand or reserved. For on-demand, you pay per minute, billed in increments of .01 minute. For reserved, you pay for the transcoding capacity of the entire queue, regardless of how much or how little you use it. Reserved pricing requires a 12-month commitment. When you use the API to create a queue, the default is on-demand.
        reservation_plan_settings: Details about the pricing plan for your reserved queue. Required for reserved queues and not applicable to on-demand queues.
        status: Initial state of the queue. If you create a paused queue, then jobs in that queue won't begin.
        tags: The tags that you want to add to the resource. You can tag resources with a key-value pair or with only a key.

    Raises:
        capo_mediaconvert.errors.bad_request_exception.BadRequestException: The service can't process your request because of a problem in the request. Please check your request form and syntax.
        capo_mediaconvert.errors.conflict_exception.ConflictException: The service couldn't complete your request because there is a conflict with the current state of the resource.
        capo_mediaconvert.errors.forbidden_exception.ForbiddenException: You don't have permissions for this action with the credentials you sent.
        capo_mediaconvert.errors.internal_server_error_exception.InternalServerErrorException: The service encountered an unexpected condition and can't fulfill your request.
        capo_mediaconvert.errors.not_found_exception.NotFoundException: The resource you requested doesn't exist.
        capo_mediaconvert.errors.service_quota_exceeded_exception.ServiceQuotaExceededException: You attempted to create more resources than the service allows based on service quotas.
        capo_mediaconvert.errors.too_many_requests_exception.TooManyRequestsException: Too many requests have been sent in too short of a time. The service limits the rate at which it will accept requests.
        capo_mediaconvert.errors.UnknownServiceError: The service returned an error code this client does not model.
    """

    def _handler(
        req: "OperationRequest[capo_mediaconvert.types.create_queue_request.CreateQueueRequest]",
    ) -> OperationResponse[
        "capo_mediaconvert.types.create_queue_response.CreateQueueResponse"
    ]:
        import capo_mediaconvert._operations.media_convert.create_queue

        output, http_response = (
            capo_mediaconvert._operations.media_convert.create_queue.create_queue(
                req.options, req.input
            )
        )
        return OperationResponse(output=output, response=http_response)

    interceptors_, options_ = self.operation_options(
        config_overrides, OperationLogging("CreateQueue")
    )
    input_: capo_mediaconvert.types.create_queue_request.CreateQueueRequest = {}
    if concurrent_jobs is not None:
        input_["concurrent_jobs"] = concurrent_jobs
    if description is not None:
        input_["description"] = description
    if maximum_concurrent_feeds is not None:
        input_["maximum_concurrent_feeds"] = maximum_concurrent_feeds
    if name is not None:
        input_["name"] = name
    if pricing_plan is not None:
        input_["pricing_plan"] = pricing_plan
    if reservation_plan_settings is not None:
        input_["reservation_plan_settings"] = reservation_plan_settings
    if status is not None:
        input_["status"] = status
    if tags is not None:
        input_["tags"] = tags

    response = execute_pipeline(
        OperationRequest(input=input_, options=options_),
        handler=_handler,
        interceptors=list(interceptors_),
    )
    response.response.close()
    return response.output