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

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

                Author: ASF GitHub Bot
            Created on: 02/Apr/20 04:35
            Start Date: 02/Apr/20 04:35
    Worklog Time Spent: 10m 
      Work Description: autumnust commented on pull request #2947: 
GOBBLIN-1107: Lazily initialize Helix TaskStateModelFactory in Gobbli…
URL: https://github.com/apache/incubator-gobblin/pull/2947#discussion_r402042445
 
 

 ##########
 File path: 
gobblin-cluster/src/main/java/org/apache/gobblin/cluster/GobblinTaskRunner.java
 ##########
 @@ -191,6 +179,17 @@ public GobblinTaskRunner(String applicationName,
 
     this.containerMetrics = buildContainerMetrics();
 
+    logger.info("GobblinTaskRunner({}): applicationName {}, helixInstanceName 
{}, applicationId {}, taskRunnerId {}, config {}, appWorkDir {}",
+        this.isTaskDriver? "taskDriver" : "worker",
+        applicationName,
+        helixInstanceName,
+        applicationId,
+        taskRunnerId,
+        config,
+        appWorkDirOptional);
+  }
+
+  private synchronized TaskRunnerSuiteBase initTaskStateModelFactory() throws 
ReflectiveOperationException {
 
 Review comment:
   this method has both return value and side effect which should be 
[avoided](https://softwareengineering.stackexchange.com/questions/289948/origin-of-a-method-should-return-a-value-or-have-side-effects-but-not-both).
 Shall we consider divide it into two: get TaskRunnerSuite  and 
initTaskStateModelFactory(TaskRunnerSuiteBase) if you want to make the init as 
a method ?
 
----------------------------------------------------------------
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: 414475)
    Time Spent: 50m  (was: 40m)

> Lazily initialize Helix TaskStateModelFactory in GobblinTaskRunner
> ------------------------------------------------------------------
>
>                 Key: GOBBLIN-1107
>                 URL: https://issues.apache.org/jira/browse/GOBBLIN-1107
>             Project: Apache Gobblin
>          Issue Type: Improvement
>          Components: gobblin-cluster
>    Affects Versions: 0.15.0
>            Reporter: Sudarshan Vasudevan
>            Assignee: Hung Tran
>            Priority: Major
>             Fix For: 0.15.0
>
>          Time Spent: 50m
>  Remaining Estimate: 0h
>
> Current behavior eagerly initializes the taskStateModelFactory inside the 
> constructor. This causes Helix task assignment to be stuck when a Helix 
> manager connection needs to be retried.



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

Reply via email to