File tree Expand file tree Collapse file tree 2 files changed +7
-10
lines changed Expand file tree Collapse file tree 2 files changed +7
-10
lines changed Original file line number Diff line number Diff line change @@ -547,9 +547,14 @@ func (e *InvokerExecuteTaskExecutor) startWorkflow(
547
547
return nil , err
548
548
}
549
549
550
+ // realTime may be slightly past the time of the action's first scheduled WFT.
551
+ realTime := time .Now ()
552
+ desiredTime := start .ActualTime
553
+ e .MetricsHandler .Timer (metrics .ScheduleActionDelay .Name ()).Record (realTime .Sub (desiredTime .AsTime ()))
554
+
550
555
return & schedulepb.ScheduleActionResult {
551
- ScheduleTime : start . ActualTime ,
552
- ActualTime : timestamppb .New (time . Now () ),
556
+ ScheduleTime : desiredTime ,
557
+ ActualTime : timestamppb .New (realTime ),
553
558
StartWorkflowResult : & commonpb.WorkflowExecution {
554
559
WorkflowId : workflowID ,
555
560
RunId : result .RunId ,
Original file line number Diff line number Diff line change @@ -1216,10 +1216,6 @@ var (
1216
1216
"schedule_action_success" ,
1217
1217
WithDescription ("The number of schedule actions that were successfully taken by a schedule" ),
1218
1218
)
1219
- ScheduleActionAttempt = NewCounterDef (
1220
- "schedule_action_attempt" ,
1221
- WithDescription ("The number of schedule actions attempts" ),
1222
- )
1223
1219
ScheduleActionErrors = NewCounterDef (
1224
1220
"schedule_action_errors" ,
1225
1221
WithDescription ("The number of failed attempts from starting schedule actions" ),
@@ -1236,10 +1232,6 @@ var (
1236
1232
"schedule_action_delay" ,
1237
1233
WithDescription ("Delay between when scheduled actions should/actually happen" ),
1238
1234
)
1239
- ScheduleActionDropped = NewCounterDef (
1240
- "schedule_action_dropped" ,
1241
- WithDescription ("The number of schedule actions that failed to start" ),
1242
- )
1243
1235
1244
1236
// Worker Versioning
1245
1237
WorkerDeploymentCreated = NewCounterDef ("worker_deployment_created" )
You can’t perform that action at this time.
0 commit comments