You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@gobblin.apache.org by GitBox <gi...@apache.org> on 2019/11/21 21:22:37 UTC

[GitHub] [incubator-gobblin] jack-moseley commented on a change in pull request #2820: [GOBBLIN-974] Avoid updating job/flow status if messages arrive out of order

jack-moseley commented on a change in pull request #2820: [GOBBLIN-974] Avoid updating job/flow status if messages arrive out of order
URL: https://github.com/apache/incubator-gobblin/pull/2820#discussion_r349324016
 
 

 ##########
 File path: gobblin-service/src/main/java/org/apache/gobblin/service/monitoring/KafkaJobStatusMonitor.java
 ##########
 @@ -146,6 +151,19 @@ static void addJobStatusToStateStore(org.apache.gobblin.configuration.State jobS
     String storeName = jobStatusStoreName(flowGroup, flowName);
     String tableName = jobStatusTableName(flowExecutionId, jobGroup, jobName);
 
+    List<org.apache.gobblin.configuration.State> states = stateStore.getAll(storeName, tableName);
+    if (states.size() > 0) {
+      String previousStatus = states.get(states.size() - 1).getProp(JobStatusRetriever.EVENT_NAME_FIELD);
+      String currentStatus = jobStatus.getProp(JobStatusRetriever.EVENT_NAME_FIELD);
 
 Review comment:
   It returns null.

----------------------------------------------------------------
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


With regards,
Apache Git Services