@Generated(value="jsii-pacmak/1.67.0 (build 2c027f5)", date="2022-09-19T20:26:36.819Z") @Stability(value=Stable) public abstract class Signals extends software.amazon.jsii.JsiiObject
If you do configure waiting for signals, you should make sure the instances
invoke cfn-signal somewhere in their UserData to signal that they have
started up (either successfully or unsuccessfully).
Signals are used both during intial creation and subsequent updates.
Example:
Vpc vpc;
InstanceType instanceType;
IMachineImage machineImage;
AutoScalingGroup.Builder.create(this, "ASG")
.vpc(vpc)
.instanceType(instanceType)
.machineImage(machineImage)
// ...
.init(CloudFormationInit.fromElements(InitFile.fromString("/etc/my_instance", "This got written during instance startup")))
.signals(Signals.waitForAll(SignalsOptions.builder()
.timeout(Duration.minutes(10))
.build()))
.build();
| Modifier | Constructor and Description |
|---|---|
protected |
Signals() |
protected |
Signals(software.amazon.jsii.JsiiObject.InitializationMode initializationMode) |
protected |
Signals(software.amazon.jsii.JsiiObjectRef objRef) |
| Modifier and Type | Method and Description |
|---|---|
protected CfnCreationPolicy |
doRender(SignalsOptions options)
Helper to render the actual creation policy, as the logic between them is quite similar.
|
protected CfnCreationPolicy |
doRender(SignalsOptions options,
Number count)
Helper to render the actual creation policy, as the logic between them is quite similar.
|
abstract CfnCreationPolicy |
renderCreationPolicy(RenderSignalsOptions renderOptions)
Render the ASG's CreationPolicy.
|
static Signals |
waitForAll()
Wait for the desiredCapacity of the AutoScalingGroup amount of signals to have been received.
|
static Signals |
waitForAll(SignalsOptions options)
Wait for the desiredCapacity of the AutoScalingGroup amount of signals to have been received.
|
static Signals |
waitForCount(Number count)
Wait for a specific amount of signals to have been received.
|
static Signals |
waitForCount(Number count,
SignalsOptions options)
Wait for a specific amount of signals to have been received.
|
static Signals |
waitForMinCapacity()
Wait for the minCapacity of the AutoScalingGroup amount of signals to have been received.
|
static Signals |
waitForMinCapacity(SignalsOptions options)
Wait for the minCapacity of the AutoScalingGroup amount of signals to have been received.
|
jsiiAsyncCall, jsiiAsyncCall, jsiiCall, jsiiCall, jsiiGet, jsiiGet, jsiiSet, jsiiStaticCall, jsiiStaticCall, jsiiStaticGet, jsiiStaticGet, jsiiStaticSet, jsiiStaticSetprotected Signals(software.amazon.jsii.JsiiObjectRef objRef)
protected Signals(software.amazon.jsii.JsiiObject.InitializationMode initializationMode)
@Stability(value=Stable) protected Signals()
@Stability(value=Stable) @NotNull public static Signals waitForAll(@Nullable SignalsOptions options)
If no desiredCapacity has been configured, wait for minCapacity signals intead.
This number is used during initial creation and during replacing updates. During rolling updates, all updated instances must send a signal.
options - @Stability(value=Stable) @NotNull public static Signals waitForAll()
If no desiredCapacity has been configured, wait for minCapacity signals intead.
This number is used during initial creation and during replacing updates. During rolling updates, all updated instances must send a signal.
@Stability(value=Stable) @NotNull public static Signals waitForCount(@NotNull Number count, @Nullable SignalsOptions options)
You should send one signal per instance, so this represents the number of instances to wait for.
This number is used during initial creation and during replacing updates. During rolling updates, all updated instances must send a signal.
count - This parameter is required.options - @Stability(value=Stable) @NotNull public static Signals waitForCount(@NotNull Number count)
You should send one signal per instance, so this represents the number of instances to wait for.
This number is used during initial creation and during replacing updates. During rolling updates, all updated instances must send a signal.
count - This parameter is required.@Stability(value=Stable) @NotNull public static Signals waitForMinCapacity(@Nullable SignalsOptions options)
This number is used during initial creation and during replacing updates. During rolling updates, all updated instances must send a signal.
options - @Stability(value=Stable) @NotNull public static Signals waitForMinCapacity()
This number is used during initial creation and during replacing updates. During rolling updates, all updated instances must send a signal.
@Stability(value=Stable) @NotNull protected CfnCreationPolicy doRender(@NotNull SignalsOptions options, @Nullable Number count)
options - This parameter is required.count - @Stability(value=Stable) @NotNull protected CfnCreationPolicy doRender(@NotNull SignalsOptions options)
options - This parameter is required.@Stability(value=Stable) @NotNull public abstract CfnCreationPolicy renderCreationPolicy(@NotNull RenderSignalsOptions renderOptions)
renderOptions - This parameter is required.Copyright © 2022. All rights reserved.