addPostLambdaEventPermission

Exports an async function that adds the CRON job trigger to the post lambda and creates the post lambda as the target on the CRON job.

Source:

(require("addPostLambdaEventPermission"))(region, lambdaName, sourceArn, cronJobName, postLambdaArn)

Source:

Exports addPostLambdaEventPermission

Parameters:
Name Type Description
region String

This is the region of where this AWS service is deployed.

lambdaName String

This is the name of the post lambda function.

sourceArn String

This is the Event Bridge CRON job arn.

cronJobName String

This is the name of the CRON job.

postLambdaArn String

This is the post lambda function arn.

Methods

(async, inner) addLambdaPermission(lambda, lambdaName, sourceArn) → {undefined}

Source:

Adds event bridge permission to lambda (CRON JOB)

Parameters:
Name Type Description
lambda LambdaClient

This is the lambda client.

lambdaName String

This is the name of the lambda function.

sourceArn String

This is the Event Bridge CRON job arn.

Returns:
Type
undefined

(async, inner) createTarget(cloudwatchEvent, cronJobName, postLambdaArn) → {undefined}

Source:

Adds the post lambda as the target to the event bridge CRON job.

Parameters:
Name Type Description
cloudwatchEvent CloudWatchEventsClient

This is the cloudwatch event client.

cronJobName String

This is the name of the CRON job.

postLambdaArn String

This is the post lambda function arn.

Returns:
Type
undefined