I have a simple state machine using the AWS CDK adapter with cdktf where I am trying to use nested workflows via the StepFunctionsStartExecution optimized integration.
// create child state machine
const manualReviewStateMachine = new StateMachine(...)
// in the parent state machine...
return new sfnTasks.StepFunctionsStartExecution(this.scope, `Manual Review`, {
stateMachine: manualReviewStateMachine,
integrationPattern: IntegrationPattern.RUN_JOB,
input: sfn.TaskInput.fromObject({...})
})
However, the cdktf JSON output doesn't appear to be valid because the reference to the child state machine uses a Ref attribute that doesn't exist (modified the TF json output slightly to make it more readable, but the key is the "Ref" attribute in the StateMachineArn field value for the Manual Review state):
"Manual Review":{
"Next": "...",
"Type": "Task",
"Resource": join("", "arn:", data.aws_partition.aws-adapter_aws-partition_68D67DE5.partition, ":states:::states:startExecution.sync:2"),
"Parameters": {
"Input": { ... },
"StateMachineArn": jsondecode(aws_cloudcontrolapi_resource.aws-adapter_ParallelComplianceLegalEntityReviewManualReviewStateMachine0B6709C9_D8D91C4C.properties)["Ref"]
}
}
If I try to deploy, it complains about a missing Ref attribute. Note that if I change the Ref above to Arn and deploy, it deploys successfully. It seems that the StateMachine mapping for the AWS CDK adapter must not be including the Ref attribute?
I have a simple state machine using the AWS CDK adapter with cdktf where I am trying to use nested workflows via the
StepFunctionsStartExecutionoptimized integration.However, the cdktf JSON output doesn't appear to be valid because the reference to the child state machine uses a
Refattribute that doesn't exist (modified the TF json output slightly to make it more readable, but the key is the"Ref"attribute in theStateMachineArnfield value for theManual Reviewstate):If I try to deploy, it complains about a missing
Refattribute. Note that if I change theRefabove toArnand deploy, it deploys successfully. It seems that the StateMachine mapping for the AWS CDK adapter must not be including theRefattribute?