- Newest
- Most votes
- Most comments
When CloudFormation creates a resource of type AWS::Glue::Trigger
, it is in the Created state by default. To start jobs with the trigger, it needs to be in the Activated state. To put this resource in the Activated state on creation with CloudFormation, we can include the StartOnCreation
property with a value of true
in the resource definition. I have included an example below which triggers a job named Test
every hour.
Resources:
ScheduledJobTrigger:
Type: AWS::Glue::Trigger
Properties:
Type: SCHEDULED
Schedule: cron(0 * * * ? *)
Actions:
- JobName: Test
StartOnCreation: true
Documentation for the StartOnCreation
property can be found at the following link: https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-glue-trigger.html#cfn-glue-trigger-startoncreation
The current status of your Glue Trigger can be found on the Glue Trigger console page.
Alternatively, the trigger can be activated from the Glue Trigger console page, or using the awscli:
aws glue start-trigger --name <trigger name>
Please add a reply if you need any other help with this topic.
Relevant content
- asked 7 months ago