[ 
https://issues.apache.org/jira/browse/GOBBLIN-1542?focusedWorklogId=665357&page=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-665357
 ]

ASF GitHub Bot logged work on GOBBLIN-1542:
-------------------------------------------

                Author: ASF GitHub Bot
            Created on: 13/Oct/21 20:55
            Start Date: 13/Oct/21 20:55
    Worklog Time Spent: 10m 
      Work Description: autumnust commented on a change in pull request #3393:
URL: https://github.com/apache/gobblin/pull/3393#discussion_r728440001



##########
File path: 
gobblin-runtime/src/main/java/org/apache/gobblin/runtime/AbstractJobLauncher.java
##########
@@ -259,6 +265,27 @@ public static void setDefaultAuthenticator(Properties 
properties) {
     }
   }
 
+  /**
+   * Handle {@link WorkUnitChangeEvent}, by default it will do nothing
+   */
+  @Subscribe
+  public void handleWorkUnitChangeEvent(WorkUnitChangeEvent 
workUnitChangeEvent)
+      throws InvocationTargetException {
+    LOG.info("start to handle workunit change event");
+    try {
+      this.removeTasksFromCurrentJob(workUnitChangeEvent.getOldTaskIds());
+      this.addTasksToCurrentJob(workUnitChangeEvent.getNewWorkUnits());
+    } catch (Exception e) {

Review comment:
       you may want to distinguish different type of exception and log them 
accordingly especially for things like retry failure. 




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

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


Issue Time Tracking
-------------------

    Worklog Id:     (was: 665357)
    Time Spent: 5h  (was: 4h 50m)

> Integrate with Helix API to add/remove task from a running helix job
> --------------------------------------------------------------------
>
>                 Key: GOBBLIN-1542
>                 URL: https://issues.apache.org/jira/browse/GOBBLIN-1542
>             Project: Apache Gobblin
>          Issue Type: New Feature
>            Reporter: Zihan Li
>            Priority: Major
>          Time Spent: 5h
>  Remaining Estimate: 0h
>
> Integrate with Helix API to add/remove task from a running helix job. This 
> ticket also contains the API change that Source need to contact with 
> JobLauncher to notify that there is some change in workunit. This will enable 
> us to dynamically add/delete task from running job and save resources. 



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

Reply via email to