Menu
AWS Glue
Developer Guide

Job Triggers

Data Types

Trigger Structure

Information about a specific trigger.

Fields

  • Name – String, matching the Single-line string pattern.

    Name of the trigger.

  • Id – String, matching the Single-line string pattern.

    The trigger ID.

  • Type – String (valid values: SCHEDULED | CONDITIONAL | ON_DEMAND).

    The type of trigger that this is.

  • State – String (valid values: CREATING | CREATED | ACTIVATING | ACTIVATED | DEACTIVATING | DEACTIVATED | DELETING | UPDATING).

    The current state of the trigger.

  • Description – Description string, matching the URI address multi-line string pattern.

    A description of this trigger.

  • Schedule – String.

    A cron expression used to specify the schedule (see Time-Based Schedules for Jobs and Crawlers. For example, to run something every day at 12:15 UTC, you would specify: cron(15 12 * * ? *).

  • Actions – An array of Actions.

    The actions initiated by this trigger.

  • Predicate – A Predicate object.

    The predicate of this trigger.

TriggerUpdate Structure

A structure used to provide information used to updata a trigger.

Fields

  • Name – String, matching the Single-line string pattern.

    The name of the trigger.

  • Description – Description string, matching the URI address multi-line string pattern.

    A description of this trigger.

  • Schedule – String.

    An updated cron expression used to specify the schedule (see Time-Based Schedules for Jobs and Crawlers. For example, to run something every day at 12:15 UTC, you would specify: cron(15 12 * * ? *).

  • Actions – An array of Actions.

    The actions initiated by this trigger.

  • Predicate – A Predicate object.

    The predicate of this trigger, which defines when it will fire.

Predicate Structure

Defines the predicate of the trigger, which determines when it fires.

Fields

  • Logical – String (valid values: AND).

    Currently "OR" is not supported.

  • Conditions – An array of Conditions.

    A list of the conditions that determine when the trigger will fire.

Condition Structure

Defines a condition under which a trigger fires.

Fields

  • LogicalOperator – String (valid values: EQUALS).

    A logical operator.

  • JobName – String, matching the Single-line string pattern.

    The name of the job in question.

  • State – String (valid values: STARTING | RUNNING | STOPPING | STOPPED | SUCCEEDED | FAILED).

    The condition state.

Action Structure

Defines an action to be initiated by a trigger.

Fields

  • JobName – String, matching the Single-line string pattern.

    The name of a job to be executed.

  • Arguments – An array of UTF-8 string–to–UTF-8 string mappings.

    Arguments to be passed to the job.

Operations

CreateTrigger Action (Python: create_trigger)

Creates a new trigger.

Request

  • Name – String, matching the Single-line string pattern. Required.

    The name to assign to the new trigger.

  • Type – String (valid values: SCHEDULED | CONDITIONAL | ON_DEMAND). Required.

    The type of the new trigger.

  • Schedule – String.

    A cron expression used to specify the schedule (see Time-Based Schedules for Jobs and Crawlers. For example, to run something every day at 12:15 UTC, you would specify: cron(15 12 * * ? *).

  • Predicate – A Predicate object.

    A predicate to specify when the new trigger should fire.

  • Actions – An array of Actions. Required.

    The actions initiated by this trigger when it fires.

  • Description – Description string, matching the URI address multi-line string pattern.

    A description of the new trigger.

Response

Errors

  • AlreadyExistsException

  • InvalidInputException

  • InternalServiceException

  • OperationTimeoutException

  • ResourceNumberLimitExceededException

StartTrigger Action (Python: start_trigger)

Starts an existing trigger.

Request

Response

Errors

  • InvalidInputException

  • InternalServiceException

  • EntityNotFoundException

  • OperationTimeoutException

  • ResourceNumberLimitExceededException

  • ConcurrentRunsExceededException

GetTrigger Action (Python: get_trigger)

Retrieves the definition of a trigger.

Request

Response

  • Trigger – A Trigger object.

    The requested trigger definition.

Errors

  • EntityNotFoundException

  • InvalidInputException

  • InternalServiceException

  • OperationTimeoutException

GetTriggers Action (Python: get_triggers)

Gets all the triggers associated with a job.

Request

  • NextToken – String.

    A continuation token, if this is a continuation call.

  • DependentJobName – String, matching the Single-line string pattern.

    The name of the job for which to retrieve triggers.

  • MaxResults – Number (integer).

    The maximum size of the response.

Response

  • Triggers – An array of Triggers.

    A list of triggers for the specified job.

  • NextToken – String.

    A continuation token, if not all the requested triggers have yet been returned.

Errors

  • EntityNotFoundException

  • InvalidInputException

  • InternalServiceException

  • OperationTimeoutException

UpdateTrigger Action (Python: update_trigger)

Updates a trigger definition.

Request

  • Name – String, matching the Single-line string pattern. Required.

    The name of the trigger to update.

  • TriggerUpdate – A TriggerUpdate object. Required.

    The new values with which to update the trigger.

Response

  • Trigger – A Trigger object.

    The resulting trigger definition.

Errors

  • InvalidInputException

  • InternalServiceException

  • EntityNotFoundException

  • OperationTimeoutException

StopTrigger Action (Python: stop_trigger)

Stops a specified trigger.

Request

Response

Errors

  • InvalidInputException

  • InternalServiceException

  • EntityNotFoundException

  • OperationTimeoutException

DeleteTrigger Action (Python: delete_trigger)

Deletes a specified trigger.

Request

Response

Errors

  • InvalidInputException

  • InternalServiceException

  • OperationTimeoutException