Search code examples
amazon-web-servicesaws-lambdaaws-step-functions

AWS Step Functions execution error: The resource provided in the resource ARN is not supported


I have a project that uses AWS services. In it there is a state function defined in this way:

{
  "Comment": "WESII internal pipeline",
  "StartAt": "FileUploadingWatcher",
  "States": {
    "FileUploadingWatcher": {
      "Type": "Task",
      "Resource": "arn:aws:state:::lambda:invoke.waitForTaskToken",
      "Parameters": {
        "FunctionName": "WesiiPipelines-dev-FileUploading",
        "Payload": {
          "token.$": "$$.Task.Token",
          "metadata.$": "$.metadata"
        }
      },
      "ResultPath": "$.uploaded_files",
      "Next": "ProcessingWorker"
    },
    "ProcessingWorker": {
      "Type": "Task",
      "Resource": "arn:aws:states:eu-west-1:777224273129:activity:ProcessingWorker-dev",
      "ResultPath": "$.processing_location",
      "End": true
    }
  }
}

In the last week every execution of the step-functions fails giving this error:

An error occurred while executing the state 'FileUploadingWatcher' (entered at the event id #2). The resource provided in the resource ARN is not supported.

enter image description here

I haven't done any deploy in a year, so I have not changed any of the aws resources used by the project. What could be causing this error?


Solution

  • You are facing this issue due to a typo in the arn containing a missing s. The correct resource name you require is:

    arn:aws:states:::lambda:invoke.waitForTaskToken
    

    You did mention this has not changed in over a year, are there confirmed execution logs showing this state being entered and exited without failure?