You are viewing a plain text version of this content. The canonical link for it is here.
Posted to github@beam.apache.org by GitBox <gi...@apache.org> on 2021/02/17 17:59:32 UTC

[GitHub] [beam] pabloem commented on a change in pull request #13993: Fix IllegalArgumentException in Interval

pabloem commented on a change in pull request #13993:
URL: https://github.com/apache/beam/pull/13993#discussion_r577825729



##########
File path: runners/google-cloud-dataflow-java/worker/src/main/java/org/apache/beam/runners/dataflow/worker/DataflowWorkUnitClient.java
##########
@@ -215,14 +214,15 @@ public WorkItemServiceState reportWorkItemStatus(WorkItemStatus workItemStatus)
         && DataflowWorkerLoggingMDC.getStageName() != null) {
       DateTime startTime = stageStartTime.get();
       if (startTime != null) {
-        // This thread should have been tagged with the stage start time during getWorkItem(),
-        Interval elapsed = new Interval(startTime, endTime);
+        // elapsed time can be negative by time correction
+        long elapsed = endTime.getMillis() - startTime.getMillis();

Review comment:
       Can you explain how this is different from what we were doing before?




----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org