By using AWS re:Post, you agree to the Terms of Use
/CDK AWS trigger with type EVENT/

CDK AWS trigger with type EVENT

0

Hi team, I want to create a glue trigger via the CDK and associate it with a workflow,

after 5 eventBridge events => glue workflow as destination fire my glue trigger of type = "EVENT"=> glue trigger call the job

the trigger is of type "EVENT"

I want to add the following config to my trigger via CDK :

"EventBatchingCondition": {
            "BatchSize": 5,
            "BatchWindow": 900
        }

but did not find any object allowing me to add this config to the CfnTrigger.

this is my CDK code :

const glueEdwWorkflowTrigger = new glue.CfnTrigger(
      this,
      "trigger",
      {
        name: "trigger",
        workflowName: myWorkFlow.name,
        type: "EVENT",

        predicate:{conditions:[{}]},
        actions: [
          {
            jobName: myCfnJob.name,
            arguments: {},
          },
        ]
      }
    );

how can I add EventBatchingCondition (BatchSize) info to my CfnTrigger? so that my trigger is fired after 5 event bridge events

thanks a lot.

1 Answers
0

Unfortunately, you cannot specify EventBatchingCondition yet in a AWS::Glue::Trigger CloudFormation resource, which CDK depends on. Please follow this GitHub issue to track progress on coverage: https://github.com/aws-cloudformation/cloudformation-coverage-roadmap/issues/967

In the meantime, as a workaround you could manually call the Glue API to add this property. One option may be to do this as part of a CDK trigger.

answered 2 months ago

You are not logged in. Log in to post an answer.

A good answer clearly answers the question and provides constructive feedback and encourages professional growth in the question asker.

Guidelines for Answering Questions