问题
My state in a step function flow returns an error of state/task returned a result with a size exceeding the maximum number of characters service limit.
. In the step function documentation, the limit for characters for input/output is 32,768 characters
. Upon checking the total characters of my result data if falls below the limit. Are there any other scenarios that it will throw that error? Thanks!
回答1:
32KB is the maximum size of the payload that can be passed between states. You could also exceed this limit from a Map or Parallel state, whose final output is an array with the output of each iteration or branch.
The recommended solution from the Step Functions documentation is to store the data somewhere else (e.g. S3) and pass around the ARN instead of raw JSON.
https://docs.aws.amazon.com/step-functions/latest/dg/avoid-exec-failures.html
You can also use OutputPath
to reduce the output to the fields you want to pass to the next state.
https://docs.aws.amazon.com/step-functions/latest/dg/input-output-outputpath.html
来源:https://stackoverflow.com/questions/55702571/step-function-exceeding-the-maximum-number-of-characters-service-limit