AWS Step cannot correctly invoke AWS Batch job parameters

Viewed 242

I am calling an AWS Batch job via an AWS Step function. My requirement is that I need to pass a parameter via the step function, so that I can pass different parameter each time the Batch job is run. This is my Step function file

{
  "StartAt": "Process Job",
  "TimeoutSeconds": 3600,
  "States": {
    "Process Job": {
      "Type": "Parallel",
      "End": true,
      "Branches": [
        {
          "StartAt": "Run command",
          "States": {
            "Run command": {
              "Type": "Task",
              "Resource": "arn:aws:states:::batch:submitJob.sync",
              "Parameters": {
                "JobDefinition": "********",
                "JobName": "ExtractFeatures",
                "JobQueue": "test_queue",
                "Parameters": {
                  "Name": "greeting",
                  "Value": "Testing"
                }
              },
              "End": true
            }
          }
        }
      ]
    }
  }
}

I get this error message, even though I am passing the parameter to the job.

No parameter found for reference greeting (Service: AWSBatch; Status Code: 400; Error Code: ClientException; Request ID: 4fef07c4-ec2a; Proxy: null)
0 Answers
Related