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

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

                Author: ASF GitHub Bot
            Created on: 07/Jun/19 21:49
            Start Date: 07/Jun/19 21:49
    Worklog Time Spent: 10m 
      Work Description: htran1 commented on pull request #2665: [GOBBLIN-798] 
Clean up workflows from Helix when the Gobblin applicat…
URL: https://github.com/apache/incubator-gobblin/pull/2665#discussion_r291764934
 
 

 ##########
 File path: 
gobblin-cluster/src/main/java/org/apache/gobblin/cluster/GobblinClusterManager.java
 ##########
 @@ -264,6 +268,12 @@ public synchronized void start() {
     this.eventBus.register(this);
     this.multiManager.connect();
 
+    // Standalone mode registers a handler to clean up on leadership change, 
so don't do the cleanup
+    // now even if the option to clean up on startup is set.
+    if (this.cleanUpJobsOnStartup && !this.isStandaloneMode) {
 
 Review comment:
   It is to avoid duplicate clean up calls. The code would be correct without 
this check. A standalone mode manager can transition through multiple 
leadership change events and there is only one clean up call per transition, so 
there is no need to dedupe/no-op in that code path.  
 
----------------------------------------------------------------
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:
us...@infra.apache.org


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

    Worklog Id:     (was: 256242)
    Time Spent: 1.5h  (was: 1h 20m)

> Clean up workflows from Helix when the Gobblin application master starts
> ------------------------------------------------------------------------
>
>                 Key: GOBBLIN-798
>                 URL: https://issues.apache.org/jira/browse/GOBBLIN-798
>             Project: Apache Gobblin
>          Issue Type: Task
>            Reporter: Hung Tran
>            Assignee: Hung Tran
>            Priority: Major
>          Time Spent: 1.5h
>  Remaining Estimate: 0h
>
> If the application master aborts a new one may be spawned by YARN. The second 
> application master will resubmit the jobs. This results in duplicate jobs in 
> Helix and multiple instances of the job may run, resulting in duplicate data.
> The Gobblin application master should clean up all workflows on startup to 
> avoid executing multiple instances of a job.
>  



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Reply via email to