Class SfnStateMachine
java.lang.Object
software.amazon.jsii.JsiiObject
software.amazon.awscdk.services.events.targets.SfnStateMachine
- All Implemented Interfaces:
IRuleTarget
,software.amazon.jsii.JsiiSerializable
@Generated(value="jsii-pacmak/1.103.1 (build bef2dea)",
date="2024-10-11T15:55:59.282Z")
@Stability(Stable)
public class SfnStateMachine
extends software.amazon.jsii.JsiiObject
implements IRuleTarget
Use a StepFunctions state machine as a target for Amazon EventBridge rules.
Example:
import software.amazon.awscdk.services.iam.*; import software.amazon.awscdk.services.stepfunctions.*; Rule rule = Rule.Builder.create(this, "Rule") .schedule(Schedule.rate(Duration.minutes(1))) .build(); Queue dlq = new Queue(this, "DeadLetterQueue"); Role role = Role.Builder.create(this, "Role") .assumedBy(new ServicePrincipal("events.amazonaws.com")) .build(); StateMachine stateMachine = StateMachine.Builder.create(this, "SM") .definition(Wait.Builder.create(this, "Hello").time(WaitTime.duration(Duration.seconds(10))).build()) .build(); rule.addTarget(SfnStateMachine.Builder.create(stateMachine) .input(RuleTargetInput.fromObject(Map.of("SomeParam", "SomeValue"))) .deadLetterQueue(dlq) .role(role) .build());
-
Nested Class Summary
Nested classes/interfaces inherited from class software.amazon.jsii.JsiiObject
software.amazon.jsii.JsiiObject.InitializationMode
Nested classes/interfaces inherited from interface software.amazon.awscdk.services.events.IRuleTarget
IRuleTarget.Jsii$Default, IRuleTarget.Jsii$Proxy
-
Constructor Summary
ModifierConstructorDescriptionSfnStateMachine
(IStateMachine machine) SfnStateMachine
(IStateMachine machine, SfnStateMachineProps props) protected
SfnStateMachine
(software.amazon.jsii.JsiiObject.InitializationMode initializationMode) protected
SfnStateMachine
(software.amazon.jsii.JsiiObjectRef objRef) -
Method Summary
Modifier and TypeMethodDescriptionReturns a properties that are used in an Rule to trigger this State Machine.Returns a properties that are used in an Rule to trigger this State Machine.Methods inherited from class software.amazon.jsii.JsiiObject
jsiiAsyncCall, jsiiAsyncCall, jsiiCall, jsiiCall, jsiiGet, jsiiGet, jsiiSet, jsiiStaticCall, jsiiStaticCall, jsiiStaticGet, jsiiStaticGet, jsiiStaticSet, jsiiStaticSet
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface software.amazon.jsii.JsiiSerializable
$jsii$toJson
-
Constructor Details
-
SfnStateMachine
protected SfnStateMachine(software.amazon.jsii.JsiiObjectRef objRef) -
SfnStateMachine
protected SfnStateMachine(software.amazon.jsii.JsiiObject.InitializationMode initializationMode) -
SfnStateMachine
@Stability(Stable) public SfnStateMachine(@NotNull IStateMachine machine, @Nullable SfnStateMachineProps props) - Parameters:
machine
- This parameter is required.props
-
-
SfnStateMachine
- Parameters:
machine
- This parameter is required.
-
-
Method Details
-
bind
@Stability(Stable) @NotNull public RuleTargetConfig bind(@NotNull IRule _rule, @Nullable String _id) Returns a properties that are used in an Rule to trigger this State Machine.- Specified by:
bind
in interfaceIRuleTarget
- Parameters:
_rule
- This parameter is required._id
-- See Also:
-
bind
Returns a properties that are used in an Rule to trigger this State Machine.- Specified by:
bind
in interfaceIRuleTarget
- Parameters:
_rule
- This parameter is required.- See Also:
-
getMachine
-