ScheduledAction
Source:
src/AWS/ApplicationAutoScaling/ScheduledAction.ts
An Application Auto Scaling scheduled action — adjusts a scalable target’s
minimum and/or maximum capacity on a one-time (at(...)) or recurring
(cron(...) / rate(...)) schedule.
The action applies to the scalable target identified by the
(serviceNamespace, resourceId, scalableDimension) triple, which must
be registered (see ScalableTarget) before the action is created —
pass the target’s outputs so deployment orders correctly.
Scheduling Capacity Changes
Section titled “Scheduling Capacity Changes”Scale Out for Business Hours
yield* ScheduledAction("BusinessHoursScaleOut", { serviceNamespace: target.serviceNamespace, resourceId: target.resourceId, scalableDimension: target.scalableDimension, schedule: "cron(0 8 ? * MON-FRI *)", timezone: "America/Los_Angeles", scalableTargetAction: { MinCapacity: 3, MaxCapacity: 10 },});One-Time Capacity Bump
yield* ScheduledAction("LaunchDayBump", { serviceNamespace: target.serviceNamespace, resourceId: target.resourceId, scalableDimension: target.scalableDimension, schedule: "at(2030-01-01T00:00:00)", scalableTargetAction: { MinCapacity: 5 },});