AWS步骤功能和可选参数

问题描述 投票:7回答:1

我希望将参数的默认值传递给step函数

例如,

"Parameters": {
   "foo.$": "$.foo" OR "bar" if "$.foo" not specified
}

是否可以通过JSONPath本地执行此操作,或者我必须使用选择+通过状态?

如果输入中未指定参数时,有一种不中断的方法,我什至愿意使用选择/传递。

如果我在输入中不包含"foo": "",则会收到类似"JSONPath ... could not be found in the input."的错误

amazon-web-services jsonpath aws-step-functions
1个回答
0
投票

我能够创建一个cloudwatch规则来解决此问题,该规则每次运行stepfunction时都会插入json。

如果您转到Cloudwatch>创建规则>目标>步进功能>配置输入>常量(JSON文本)

您可以在其中插入默认json,每次运行stepfunction时都会插入json。

© www.soinside.com 2019 - 2024. All rights reserved.