CfnScheduleProps Struct
Properties for defining a CfnSchedule.
Example
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import { aws_scheduler as scheduler } from 'aws-cdk-lib';
declare const tags: any;
const cfnScheduleProps: scheduler.CfnScheduleProps = {
flexibleTimeWindow: {
mode: 'mode',
// the properties below are optional
maximumWindowInMinutes: 123,
},
scheduleExpression: 'scheduleExpression',
target: {
arn: 'arn',
roleArn: 'roleArn',
// the properties below are optional
deadLetterConfig: {
arn: 'arn',
},
ecsParameters: {
taskDefinitionArn: 'taskDefinitionArn',
// the properties below are optional
capacityProviderStrategy: [{
capacityProvider: 'capacityProvider',
// the properties below are optional
base: 123,
weight: 123,
}],
enableEcsManagedTags: false,
enableExecuteCommand: false,
group: 'group',
launchType: 'launchType',
networkConfiguration: {
awsvpcConfiguration: {
subnets: ['subnets'],
// the properties below are optional
assignPublicIp: 'assignPublicIp',
securityGroups: ['securityGroups'],
},
},
placementConstraints: [{
expression: 'expression',
type: 'type',
}],
placementStrategy: [{
field: 'field',
type: 'type',
}],
platformVersion: 'platformVersion',
propagateTags: 'propagateTags',
referenceId: 'referenceId',
tags: tags,
taskCount: 123,
},
eventBridgeParameters: {
detailType: 'detailType',
source: 'source',
},
input: 'input',
kinesisParameters: {
partitionKey: 'partitionKey',
},
retryPolicy: {
maximumEventAgeInSeconds: 123,
maximumRetryAttempts: 123,
},
sageMakerPipelineParameters: {
pipelineParameterList: [{
name: 'name',
value: 'value',
}],
},
sqsParameters: {
messageGroupId: 'messageGroupId',
},
},
// the properties below are optional
description: 'description',
endDate: 'endDate',
groupName: 'groupName',
kmsKeyArn: 'kmsKeyArn',
name: 'name',
scheduleExpressionTimezone: 'scheduleExpressionTimezone',
startDate: 'startDate',
state: 'state',
};
Properties
Depending on the schedule's recurrence expression, invocations might stop on, or before, the EndDate you specify. EventBridge Scheduler ignores EndDate for one-time schedules.
flexibleTimeWindowIResolvable | CfnSchedule.FlexibleTimeWindowPropertyflexible_time_windowtyping.Union[IResolvable, FlexibleTimeWindowProperty]flexibleTimeWindowIResolvableFlexibleTimeWindowIResolvableFlexibleTimeWindowinterface{}required#kmsKeyArnstring | IKeyRefkms_key_arntyping.Union[str, IKeyRef]kmsKeyArnStringKmsKeyArnstringKmsKeyArninterface{}#scheduleExpressionstringschedule_expressionstrscheduleExpressionStringScheduleExpressionstringScheduleExpression*stringrequired#notes
atexpression -at(yyyy-mm-ddThh:mm:ss)rateexpression -rate(value unit)cronexpression -cron(fields)
You can use at expressions to create one-time schedules that invoke a target once, at the time and in the time zone, that you specify. You can use rate and cron expressions to create recurring schedules. Rate-based schedules are useful when you want to invoke a target at regular intervals, such as every 15 minutes or every five days. Cron-based schedules are useful when you want to invoke a target periodically at a specific time, such as at 8:00 am (UTC+0) every 1st day of the month.
A cron expression consists of six fields separated by white spaces: (minutes hours day_of_month month day_of_week year) .
A rate expression consists of a value as a positive integer, and a unit with the following options: minute | minutes | hour | hours | day | days
For more information and examples, see Schedule types on EventBridge Scheduler in the EventBridge Scheduler User Guide .
scheduleExpressionTimezonestringschedule_expression_timezonestrscheduleExpressionTimezoneStringScheduleExpressionTimezonestringScheduleExpressionTimezone*string#Depending on the schedule's recurrence expression, invocations might occur on, or after, the StartDate you specify. EventBridge Scheduler ignores StartDate for one-time schedules.
Allowed Values : ENABLED | DISABLED
targetIResolvable | CfnSchedule.TargetPropertytargettyping.Union[IResolvable, TargetProperty]targetIResolvableTargetIResolvableTargetinterface{}required#