AWS Event History Event Limitation

I use step functions for a large loop, still not a problem, but on the day when my loop exceeded 8000 executions, I ran into the error "Maximum execution history size", which is equal to 25000.

Is there a solution for the absence of historical events?

Otherwise, when I can easily transfer my step functions (3 lambdas), because the aws package will ask me to rewrite the code.

Thank you so much

+4
source share
2 answers

25k , .

, ( ). , .

, "LoopProcessor" "$.breakOutOfLoop", , - .

, . , , S3 ARN / . , ( ), , LoopProcessor ( ). .

ASL, 25k:

{
  "Comment": "An example looping while avoiding the 25k event history limit.",
  "StartAt": "FirstState",
  "States": {

    "FirstState": {
      "Type": "Task",
      "Resource": "arn:aws:lambda:REGION:ACCOUNT_ID:function:FUNCTION_NAME",
      "Next": "ChoiceState"
    },

    "ChoiceState": {
      "Type" : "Choice",
      "Choices": [
        {
          "Variable": "$.breakOutOfLoop",
          "BooleanEquals": true,
          "Next": "StartNewExecution"
        }
      ],
      "Default": "LoopProcessor"
    },

    "LoopProcessor": {
      "Type" : "Task",
      "Resource": "arn:aws:lambda:REGION:ACCOUNT_ID:function:ProcessWork",
      "Next": "ChoiceState"
    },

    "StartNewExecution": {
      "Type" : "Task",
      "Resource": "arn:aws:lambda:REGION:ACCOUNT_ID:function:StartNewLooperExecution",
      "Next": "FinalState"
    },

    "FinalState": {
      "Type": "Task",
      "Resource": "arn:aws:lambda:REGION:ACCOUNT_ID:function:FUNCTION_NAME",
      "End": true
    }
  }
}

Cycle processor example

, !

+2

, , , .

, @sunnyD.

  • invoker ( ) . .
  • , /​​ , .

. (, SF) . , Cloudwatch .

, ,

  • API startExecution 500 25 .
  • , SF , SF , , SF.
0

Source: https://habr.com/ru/post/1680621/


All Articles