本文介紹如何通過控制臺和命令行工具查看執行歷史。
背景信息
歷史事件詳細的記錄了步驟的執行狀態。您可以通過這些事件了解一個流程當前的執行步驟、輸入、輸出、流程執行持續時長和失敗原因等信息。同時,Serverless 工作流服務利用這些狀態數據跟蹤流程執行,確保系統的高可用性。
使用控制臺查看執行歷史
登錄云工作流控制臺。
在流程頁面,選擇要查看的流程。
在流程詳情頁面,選擇要查看的執行。
在執行詳情頁面,查看執行的歷史記錄。
使用命令行工具查看執行歷史
您可以執行以下命令查看執行的歷史記錄。
aliyun fnf GetExecutionHistory --FlowName cli_guide_1 --ExecutionName run1
預期輸出:
{
"Events": [
{
"StepName": "",
"Type": "ExecutionStarted",
"EventId": 1,
"ScheduleEventId": 0,
"EventDetail": "{\"input\":{}}",
"Time": "2024-06-24T02:58:42.043Z"
},
{
"StepName": "pass1",
"Type": "StepEntered",
"EventId": 2,
"ScheduleEventId": 1,
"EventDetail": "{\"input\":{},\"local\":{}}",
"Time": "2024-06-24T02:58:42.077Z"
},
{
"StepName": "pass1",
"Type": "StepStarted",
"EventId": 3,
"ScheduleEventId": 2,
"EventDetail": "{\"input\":{}}",
"Time": "2024-06-24T02:58:42.091Z"
},
{
"StepName": "pass1",
"Type": "StepSucceeded",
"EventId": 4,
"ScheduleEventId": 3,
"EventDetail": "{\"output\":{}}",
"Time": "2024-06-24T02:58:42.109Z"
},
{
"StepName": "pass1",
"Type": "StepExited",
"EventId": 5,
"ScheduleEventId": 4,
"EventDetail": "{\"local\":{}}",
"Time": "2024-06-24T02:58:42.127Z"
},
{
"StepName": "pass2",
"Type": "StepEntered",
"EventId": 6,
"ScheduleEventId": 5,
"EventDetail": "{\"input\":{},\"local\":{}}",
"Time": "2024-06-24T02:58:42.144Z"
},
{
"StepName": "pass2",
"Type": "StepStarted",
"EventId": 7,
"ScheduleEventId": 6,
"EventDetail": "{\"input\":{}}",
"Time": "2024-06-24T02:58:42.156Z"
},
{
"StepName": "pass2",
"Type": "StepSucceeded",
"EventId": 8,
"ScheduleEventId": 7,
"EventDetail": "{\"output\":{}}",
"Time": "2024-06-24T02:58:42.169Z"
},
{
"StepName": "pass2",
"Type": "StepExited",
"EventId": 9,
"ScheduleEventId": 8,
"EventDetail": "{\"local\":{}}",
"Time": "2024-06-24T02:58:42.181Z"
},
{
"StepName": "",
"Type": "ExecutionSucceeded",
"EventId": 10,
"ScheduleEventId": 9,
"EventDetail": "{\"output\":{}}",
"Time": "2024-06-24T02:58:42.194Z"
}
],
"RequestId": "98802e07-44a2-221a-fbc2-ec167a871259"
}
文檔內容是否對您有幫助?