Lambda Durable Functions の IAM アクション名は CheckpointDurableExecution(単数形)
Lambda Durable Functions を AWS CLI でデプロイした際、IAM ポリシーに lambda:CheckpointDurableExecutions(複数形)を設定したら以下のエラーが出た。
User: arn:aws:sts::XXXX:assumed-role/lambda-durable-test-role/durable-basic-test
is not authorized to perform: lambda:CheckpointDurableExecution on resource: ...
because no identity-based policy allows the lambda:CheckpointDurableExecution actionエラーメッセージ自体が CheckpointDurableExecution(単数形)を要求していると教えてくれている。ポリシーを単数形に修正したら解決した。
{
"Action": [
"lambda:CheckpointDurableExecution",
"lambda:GetDurableExecutionState"
]
}ドキュメントのGetting Startedページではコンソールから作成すると自動で正しい権限が付与されるが、CLI や IaC で手動設定する場合はアクション名の単数/複数に注意が必要だ。
