Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

aws_stepfunctions: Programmatic IO #29482

Open
1 of 2 tasks
JonathanWoollett-Light opened this issue Mar 14, 2024 · 1 comment
Open
1 of 2 tasks

aws_stepfunctions: Programmatic IO #29482

JonathanWoollett-Light opened this issue Mar 14, 2024 · 1 comment
Labels
@aws-cdk/aws-stepfunctions Related to AWS StepFunctions effort/medium Medium work item – several days of effort feature-request A feature should be added or improved. p3

Comments

@JonathanWoollett-Light
Copy link

JonathanWoollett-Light commented Mar 14, 2024

Describe the feature

One of the most frustrating areas when defining step functions is defining how values are passed between states (e.g. JsonPath).

This could be greatly improved if states had properties to get their input and outputs.

Use Case

const myPass = new sfn.Pass(this, 'MyPassState', {
    parameters: {
        'someValue.$': '$$.Execution.Input'
    },
});
const mySfn = new sfn.StateMachine(this, 'MyStepFunction', {
    definition: myPass,
    timeout: cdk.Duration.hours(24)
});

Proposed Solution

const mySfn = new sfn.StateMachine(this, 'MyStepFunction', {
    timeout: cdk.Duration.hours(24)
});
const myPass = new sfn.Pass(this, 'MyPassState', {
    parameters: {
        'myValue': mySfn.input,
    },
});
mySfn.definition = myPass;

Other Information

Fixing this might be difficult, I just want to highlight this problem and see if others also experience it. Any programmatic solution would be a great improvement over using JsonPaths directly.

Acknowledgements

  • I may be able to implement this feature request
  • This feature might incur a breaking change

CDK version used

2.132.1

Environment details (OS name and version, etc.)

Linux 6.5.0-21-generic #21~22.04.1-Ubuntu x86_64 GNU/Linux

@JonathanWoollett-Light JonathanWoollett-Light added feature-request A feature should be added or improved. needs-triage This issue or PR still needs to be triaged. labels Mar 14, 2024
@github-actions github-actions bot added the @aws-cdk/aws-stepfunctions Related to AWS StepFunctions label Mar 14, 2024
@tim-finnigan tim-finnigan self-assigned this Mar 14, 2024
@tim-finnigan tim-finnigan added investigating This issue is being investigated and/or work is in progress to resolve the issue. and removed needs-triage This issue or PR still needs to be triaged. labels Mar 14, 2024
@tim-finnigan
Copy link

Thanks for the feature request. Linking aws_stepfunctions documentation for reference: https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.aws_stepfunctions-readme.html

Please feel free to share more details regarding your use case and others can 👍 this issue or add more information as well.

@tim-finnigan tim-finnigan added p2 effort/medium Medium work item – several days of effort and removed investigating This issue is being investigated and/or work is in progress to resolve the issue. labels Mar 14, 2024
@tim-finnigan tim-finnigan removed their assignment Mar 14, 2024
@pahud pahud added p3 and removed p2 labels Jun 11, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
@aws-cdk/aws-stepfunctions Related to AWS StepFunctions effort/medium Medium work item – several days of effort feature-request A feature should be added or improved. p3
Projects
None yet
Development

No branches or pull requests

3 participants