Class ScheduledActionProps
Properties for a scheduled action on an AutoScalingGroup.
Inheritance
Namespace: Amazon.CDK.AWS.AutoScaling
Assembly: Amazon.CDK.Lib.dll
Syntax (csharp)
public class ScheduledActionProps : Object, IScheduledActionProps, IBasicScheduledActionProps
Syntax (vb)
Public Class ScheduledActionProps
Inherits Object
Implements IScheduledActionProps, IBasicScheduledActionProps
Remarks
ExampleMetadata: fixture=_generated
Examples
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
using Amazon.CDK.AWS.AutoScaling;
AutoScalingGroup autoScalingGroup;
Schedule schedule;
var scheduledActionProps = new ScheduledActionProps {
AutoScalingGroup = autoScalingGroup,
Schedule = schedule,
// the properties below are optional
DesiredCapacity = 123,
EndTime = new Date(),
MaxCapacity = 123,
MinCapacity = 123,
StartTime = new Date(),
TimeZone = "timeZone"
};
Synopsis
Constructors
ScheduledActionProps() |
Properties
AutoScalingGroup | The AutoScalingGroup to apply the scheduled actions to. |
DesiredCapacity | The new desired capacity. |
EndTime | When this scheduled action expires. |
MaxCapacity | The new maximum capacity. |
MinCapacity | The new minimum capacity. |
Schedule | When to perform this action. |
StartTime | When this scheduled action becomes active. |
TimeZone | Specifies the time zone for a cron expression. |
Constructors
ScheduledActionProps()
public ScheduledActionProps()
Properties
AutoScalingGroup
The AutoScalingGroup to apply the scheduled actions to.
public IAutoScalingGroup AutoScalingGroup { get; set; }
Property Value
DesiredCapacity
The new desired capacity.
public Nullable<double> DesiredCapacity { get; set; }
Property Value
System.Nullable<System.Double>
Remarks
At the scheduled time, set the desired capacity to the given capacity.
At least one of maxCapacity, minCapacity, or desiredCapacity must be supplied.
Default: - No new desired capacity.
EndTime
When this scheduled action expires.
public Nullable<DateTime> EndTime { get; set; }
Property Value
System.Nullable<System.DateTime>
Remarks
Default: - The rule never expires.
MaxCapacity
The new maximum capacity.
public Nullable<double> MaxCapacity { get; set; }
Property Value
System.Nullable<System.Double>
Remarks
At the scheduled time, set the maximum capacity to the given capacity.
At least one of maxCapacity, minCapacity, or desiredCapacity must be supplied.
Default: - No new maximum capacity.
MinCapacity
The new minimum capacity.
public Nullable<double> MinCapacity { get; set; }
Property Value
System.Nullable<System.Double>
Remarks
At the scheduled time, set the minimum capacity to the given capacity.
At least one of maxCapacity, minCapacity, or desiredCapacity must be supplied.
Default: - No new minimum capacity.
Schedule
When to perform this action.
public Schedule Schedule { get; set; }
Property Value
Remarks
Supports cron expressions.
For more information about cron expressions, see https://en.wikipedia.org/wiki/Cron.
StartTime
When this scheduled action becomes active.
public Nullable<DateTime> StartTime { get; set; }
Property Value
System.Nullable<System.DateTime>
Remarks
Default: - The rule is activate immediately.
TimeZone
Specifies the time zone for a cron expression.
public string TimeZone { get; set; }
Property Value
System.String
Remarks
If a time zone is not provided, UTC is used by default.
Valid values are the canonical names of the IANA time zones, derived from the IANA Time Zone Database (such as Etc/GMT+9 or Pacific/Tahiti).
For more information, see https://en.wikipedia.org/wiki/List_of_tz_database_time_zones.
Default: - UTC