Skip to content

list_jobs

list_jobs(
    *,
    config_overrides: Optional[GlueClientConfig] = None,
    next_token: Optional[GenericString] = None,
    max_results: Optional[PageSize] = None,
    tags: Optional[TagsMap] = None,
) -> ListJobsResponse

Retrieves the names of all job resources in this Amazon Web Services account, or the resources with the specified tag. This operation allows you to see which resources are available in your account, and their names.

This operation takes the optional Tags field, which you can use as a filter on the response so that tagged resources can be retrieved as a group. If you choose to use tags filtering, only resources with the tag are retrieved.

Parameters:

  • next_token (Optional[GenericString], default: None ) –

    A continuation token, if this is a continuation request.

  • max_results (Optional[PageSize], default: None ) –

    The maximum size of a list to return.

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

    Specifies to return only these tagged resources.

Raises:

Source code in docs_src/capo_glue/_services/glue.py
def list_jobs(
    self,
    *,
    config_overrides: Optional[GlueClientConfig] = None,
    next_token: Optional["capo_glue.types.generic_string.GenericString"] = None,
    max_results: Optional["capo_glue.types.page_size.PageSize"] = None,
    tags: Optional["capo_glue.types.tags_map.TagsMap"] = None,
) -> "capo_glue.types.list_jobs_response.ListJobsResponse":
    """<p>Retrieves the names of all job resources in this Amazon Web Services account, or the resources with the specified tag. This operation allows you to see which resources are available in your account, and their names.</p> <p>This operation takes the optional <code>Tags</code> field, which you can use as a filter on the response so that tagged resources can be retrieved as a group. If you choose to use tags filtering, only resources with the tag are retrieved.</p>

    Args:
        next_token: <p>A continuation token, if this is a continuation request.</p>
        max_results: <p>The maximum size of a list to return.</p>
        tags: <p>Specifies to return only these tagged resources.</p>

    Raises:
        capo_glue.errors.entity_not_found_exception.EntityNotFoundException: <p>A specified entity does not exist</p>
        capo_glue.errors.internal_service_exception.InternalServiceException: <p>An internal service error occurred.</p>
        capo_glue.errors.invalid_input_exception.InvalidInputException: <p>The input provided was not valid.</p>
        capo_glue.errors.operation_timeout_exception.OperationTimeoutException: <p>The operation timed out.</p>
        capo_glue.errors.UnknownServiceError: The service returned an error code this client does not model.
    """

    def _handler(
        req: "OperationRequest[capo_glue.types.list_jobs_request.ListJobsRequest]",
    ) -> OperationResponse["capo_glue.types.list_jobs_response.ListJobsResponse"]:
        import capo_glue._operations.aws_glue.list_jobs

        output, http_response = capo_glue._operations.aws_glue.list_jobs.list_jobs(
            req.options, req.input
        )
        return OperationResponse(output=output, response=http_response)

    interceptors_, options_ = self.operation_options(
        config_overrides, OperationLogging("ListJobs")
    )
    input_: capo_glue.types.list_jobs_request.ListJobsRequest = {}
    if next_token is not None:
        input_["next_token"] = next_token
    if max_results is not None:
        input_["max_results"] = max_results
    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