Skip to content

start_crawler_schedule async

start_crawler_schedule(
    crawler_name: NameString,
    *,
    config_overrides: Optional[AsyncGlueClientConfig] = None,
) -> StartCrawlerScheduleResponse

Changes the schedule state of the specified crawler to SCHEDULED, unless the crawler is already running or the schedule state is already SCHEDULED.

Parameters:

  • crawler_name (NameString) –

    Name of the crawler to schedule.

Raises:

Source code in docs_src/capo_glue/_services/async_glue.py
async def start_crawler_schedule(
    self,
    crawler_name: "capo_glue.types.name_string.NameString",
    *,
    config_overrides: Optional[AsyncGlueClientConfig] = None,
) -> "capo_glue.types.start_crawler_schedule_response.StartCrawlerScheduleResponse":
    """<p>Changes the schedule state of the specified crawler to <code>SCHEDULED</code>, unless the crawler is already running or the schedule state is already <code>SCHEDULED</code>.</p>

    Args:
        crawler_name: <p>Name of the crawler to schedule.</p>

    Raises:
        capo_glue.errors.entity_not_found_exception.EntityNotFoundException: <p>A specified entity does not exist</p>
        capo_glue.errors.no_schedule_exception.NoScheduleException: <p>There is no applicable schedule.</p>
        capo_glue.errors.operation_timeout_exception.OperationTimeoutException: <p>The operation timed out.</p>
        capo_glue.errors.scheduler_running_exception.SchedulerRunningException: <p>The specified scheduler is already running.</p>
        capo_glue.errors.scheduler_transitioning_exception.SchedulerTransitioningException: <p>The specified scheduler is transitioning.</p>
        capo_glue.errors.UnknownServiceError: The service returned an error code this client does not model.
    """

    async def _handler(
        req: "AsyncOperationRequest[capo_glue.types.start_crawler_schedule_request.StartCrawlerScheduleRequest]",
    ) -> AsyncOperationResponse[
        "capo_glue.types.start_crawler_schedule_response.StartCrawlerScheduleResponse"
    ]:
        import capo_glue._operations.aws_glue.start_crawler_schedule

        (
            output,
            http_response,
        ) = await capo_glue._operations.aws_glue.start_crawler_schedule.async_start_crawler_schedule(
            req.options, req.input
        )
        return AsyncOperationResponse(output=output, response=http_response)

    interceptors_, options_ = self.operation_options(
        config_overrides, OperationLogging("StartCrawlerSchedule")
    )
    input_: capo_glue.types.start_crawler_schedule_request.StartCrawlerScheduleRequest = {
        "crawler_name": crawler_name
    }

    response = await aexecute_pipeline(
        AsyncOperationRequest(input=input_, options=options_),
        handler=_handler,
        interceptors=list(interceptors_),
    )
    await response.response.aclose()
    return response.output