【发布时间】:2021-12-31 13:18:09
【问题描述】:
我正在尝试使用 AWS Step Functions 中的 InputPath 过滤器来选择 JSON 状态输入的一部分以与 JSONPath 表达式一起使用。
数据
[
{
"ticker": "DE30_EUR",
"granularity": "M"
},
{
"ticker": "DE30_EUR",
"granularity": "W"
},
{
"ticker": "DE30_EUR",
"granularity": "D"
},
{
"ticker": "DE30_EUR",
"granularity": "H1"
}
]
当前 JSONPath 表达式
$[?(@.granularity==H1),?(@.granularity==D),?(@.granularity==W)]
这在使用带有上述数据的 AWS Step Functions 数据流模拟器时有效,并且仅返回粒度为“H1”、“D”或“W”的数组项。
问题
但是,当将此与 step 函数一起用作 InputPath 或 OutputPath 时,它会返回一个与数据流模拟器不同的空数组。
【问题讨论】:
标签: amazon-web-services jsonpath aws-step-functions