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 2020/08/12 18:42:57 UTC

[GitHub] [incubator-gobblin] arjun4084346 opened a new pull request #3076: add option to add spec executor configs to gaas job

arjun4084346 opened a new pull request #3076:
URL: https://github.com/apache/incubator-gobblin/pull/3076


   Dear Gobblin maintainers,
   
   Please accept this PR. I understand that it will not be reviewed until I have checked off all the steps below!
   
   
   ### JIRA
   - [ ] My PR addresses the following [Gobblin JIRA](https://issues.apache.org/jira/browse/GOBBLIN/) issues and references them in the PR title. For example, "[GOBBLIN-XXX] My Gobblin PR"
       - https://issues.apache.org/jira/browse/GOBBLIN-XXX
   
   
   ### Description
   - [ ] Here are some details about my PR, including screenshots (if applicable):
   
   
   ### Tests
   - [ ] My PR adds the following unit tests __OR__ does not need testing for this extremely good reason:
   
   
   ### Commits
   - [ ] My commits all reference JIRA issues in their subject lines, and I have squashed multiple commits if they address the same issue. In addition, my commits follow the guidelines from "[How to write a good git commit message](http://chris.beams.io/posts/git-commit/)":
       1. Subject is separated from body by a blank line
       2. Subject is limited to 50 characters
       3. Subject does not end with a period
       4. Subject uses the imperative mood ("add", not "adding")
       5. Body wraps at 72 characters
       6. Body explains "what" and "why", not "how"
   
   


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



[GitHub] [incubator-gobblin] sv2000 commented on pull request #3076: [GOBBLIN-1230] add option to add spec executor configs to gaas job

Posted by GitBox <gi...@apache.org>.
sv2000 commented on pull request #3076:
URL: https://github.com/apache/incubator-gobblin/pull/3076#issuecomment-691561437


   @arjun4084346 check travis failure. Also add JIRA number in the PR. 


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



[GitHub] [incubator-gobblin] sv2000 commented on pull request #3076: [GOBBLIN-1230] add option to add spec executor configs to gaas job

Posted by GitBox <gi...@apache.org>.
sv2000 commented on pull request #3076:
URL: https://github.com/apache/incubator-gobblin/pull/3076#issuecomment-691339863


   @arjun4084346 Please check the travis 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.

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



[GitHub] [incubator-gobblin] sv2000 commented on a change in pull request #3076: [GOBBLIN-1230] add option to add spec executor configs to gaas job

Posted by GitBox <gi...@apache.org>.
sv2000 commented on a change in pull request #3076:
URL: https://github.com/apache/incubator-gobblin/pull/3076#discussion_r487317913



##########
File path: gobblin-runtime/src/main/java/org/apache/gobblin/service/monitoring/JobStatus.java
##########
@@ -17,10 +17,11 @@
 
 package org.apache.gobblin.service.monitoring;
 
-import org.apache.gobblin.annotation.Alpha;
-
 import lombok.Builder;
 import lombok.Getter;
+import lombok.Setter;
+
+import org.apache.gobblin.annotation.Alpha;

Review comment:
       We can remove this annotation.

##########
File path: gobblin-service/src/main/java/org/apache/gobblin/service/modules/spec/JobExecutionPlan.java
##########
@@ -82,7 +87,8 @@ public JobExecutionPlan createPlan(FlowSpec flowSpec, Config jobConfig, SpecExec
      * @param flowSpec input FlowSpec.
      * @return a {@link JobSpec} corresponding to the resolved job config.
      */
-    private static JobSpec buildJobSpec(FlowSpec flowSpec, Config jobConfig, Long flowExecutionId, Config sysConfig) throws URISyntaxException {
+    private static JobSpec buildJobSpec(FlowSpec flowSpec, Config jobConfig, Long flowExecutionId, Config sysConfig, Config specExecutorConfig)

Review comment:
       Modify the javadoc to reflect the current list of arguments.

##########
File path: gobblin-service/src/main/java/org/apache/gobblin/service/modules/spec/JobExecutionPlan.java
##########
@@ -154,7 +160,7 @@ private static JobSpec buildJobSpec(FlowSpec flowSpec, Config jobConfig, Long fl
      * execution status of the job.
      * @param jobSpec representing a fully resolved {@link JobSpec}.
      */
-    private static void addAdditionalConfig(JobSpec jobSpec, Config sysConfig) {
+    private static void addAdditionalConfig(JobSpec jobSpec, Config sysConfig, Config specExecutorConfig) {

Review comment:
       Modify the javadoc.




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



[GitHub] [incubator-gobblin] arjun4084346 commented on a change in pull request #3076: [GOBBLIN-1230] add option to add spec executor configs to gaas job

Posted by GitBox <gi...@apache.org>.
arjun4084346 commented on a change in pull request #3076:
URL: https://github.com/apache/incubator-gobblin/pull/3076#discussion_r487416507



##########
File path: gobblin-runtime/src/main/java/org/apache/gobblin/runtime/AbstractJobLauncher.java
##########
@@ -414,6 +415,9 @@ public void apply(JobListener jobListener, JobContext jobContext)
         workUnitsCreationTimer.stop(this.eventMetadataGenerator.getMetadata(this.jobContext,
             EventName.WORK_UNITS_CREATION));
 
+        this.jobContext.getJobState().setProp(
+            MetricNames.NUM_WORKUNITS, workUnitStream.getMaterializedWorkUnitCollection().size());

Review comment:
       Right, it's not a codahale metric name. Can you suggest a right place? The current class (AbstractJobLauncher) ?




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



[GitHub] [incubator-gobblin] sv2000 commented on a change in pull request #3076: [GOBBLIN-1230] add option to add spec executor configs to gaas job

Posted by GitBox <gi...@apache.org>.
sv2000 commented on a change in pull request #3076:
URL: https://github.com/apache/incubator-gobblin/pull/3076#discussion_r487317913



##########
File path: gobblin-runtime/src/main/java/org/apache/gobblin/service/monitoring/JobStatus.java
##########
@@ -17,10 +17,11 @@
 
 package org.apache.gobblin.service.monitoring;
 
-import org.apache.gobblin.annotation.Alpha;
-
 import lombok.Builder;
 import lombok.Getter;
+import lombok.Setter;
+
+import org.apache.gobblin.annotation.Alpha;

Review comment:
       We can remove this annotation.

##########
File path: gobblin-service/src/main/java/org/apache/gobblin/service/modules/spec/JobExecutionPlan.java
##########
@@ -82,7 +87,8 @@ public JobExecutionPlan createPlan(FlowSpec flowSpec, Config jobConfig, SpecExec
      * @param flowSpec input FlowSpec.
      * @return a {@link JobSpec} corresponding to the resolved job config.
      */
-    private static JobSpec buildJobSpec(FlowSpec flowSpec, Config jobConfig, Long flowExecutionId, Config sysConfig) throws URISyntaxException {
+    private static JobSpec buildJobSpec(FlowSpec flowSpec, Config jobConfig, Long flowExecutionId, Config sysConfig, Config specExecutorConfig)

Review comment:
       Modify the javadoc to reflect the current list of arguments.

##########
File path: gobblin-service/src/main/java/org/apache/gobblin/service/modules/spec/JobExecutionPlan.java
##########
@@ -154,7 +160,7 @@ private static JobSpec buildJobSpec(FlowSpec flowSpec, Config jobConfig, Long fl
      * execution status of the job.
      * @param jobSpec representing a fully resolved {@link JobSpec}.
      */
-    private static void addAdditionalConfig(JobSpec jobSpec, Config sysConfig) {
+    private static void addAdditionalConfig(JobSpec jobSpec, Config sysConfig, Config specExecutorConfig) {

Review comment:
       Modify the javadoc.

##########
File path: gobblin-metrics-libs/gobblin-metrics-base/src/main/java/org/apache/gobblin/metrics/MetricNames.java
##########
@@ -22,6 +22,8 @@
  */
 public class MetricNames {
 
+  public static final String NUM_WORKUNITS = "numWorkUnits";

Review comment:
       Should this be grouped into SourceMetrics and have the metric name as "gobblin.source.numWorkUnits.created" to be consistent with other metric names?

##########
File path: gobblin-runtime/src/main/java/org/apache/gobblin/runtime/AbstractJobLauncher.java
##########
@@ -414,6 +415,9 @@ public void apply(JobListener jobListener, JobContext jobContext)
         workUnitsCreationTimer.stop(this.eventMetadataGenerator.getMetadata(this.jobContext,
             EventName.WORK_UNITS_CREATION));
 
+        this.jobContext.getJobState().setProp(
+            MetricNames.NUM_WORKUNITS, workUnitStream.getMaterializedWorkUnitCollection().size());

Review comment:
       On second reading - Is numWorkunits a CodaHale metric that gets emitted via MetricReporter? I think the metrics listed in MetricNames are intended for the reporter metrics. If numWorkUnits is intended for a different purpose, let's not add it into MetricNames class. 




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



[GitHub] [incubator-gobblin] arjun4084346 commented on a change in pull request #3076: [GOBBLIN-1230] add option to add spec executor configs to gaas job

Posted by GitBox <gi...@apache.org>.
arjun4084346 commented on a change in pull request #3076:
URL: https://github.com/apache/incubator-gobblin/pull/3076#discussion_r487283604



##########
File path: gobblin-service/src/main/java/org/apache/gobblin/service/modules/spec/JobExecutionPlan.java
##########
@@ -165,6 +171,8 @@ private static void addAdditionalConfig(JobSpec jobSpec, Config sysConfig) {
 
       Config config = jobSpec.getConfig().withFallback(ConfigUtils.getConfigOrEmpty(sysConfig, additionalConfigsPrefix));
 
+      config = config.withFallback(ConfigUtils.getConfigOrEmpty(specExecutorConfig, additionalConfigsPrefix));

Review comment:
       It will be dropped, i.e. will return b




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



[GitHub] [incubator-gobblin] asfgit closed pull request #3076: [GOBBLIN-1230] add option to add spec executor configs to gaas job

Posted by GitBox <gi...@apache.org>.
asfgit closed pull request #3076:
URL: https://github.com/apache/incubator-gobblin/pull/3076


   


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



[GitHub] [incubator-gobblin] sv2000 commented on a change in pull request #3076: [GOBBLIN-1230] add option to add spec executor configs to gaas job

Posted by GitBox <gi...@apache.org>.
sv2000 commented on a change in pull request #3076:
URL: https://github.com/apache/incubator-gobblin/pull/3076#discussion_r487319380



##########
File path: gobblin-metrics-libs/gobblin-metrics-base/src/main/java/org/apache/gobblin/metrics/MetricNames.java
##########
@@ -22,6 +22,8 @@
  */
 public class MetricNames {
 
+  public static final String NUM_WORKUNITS = "numWorkUnits";

Review comment:
       Should this be grouped into SourceMetrics and have the metric name as "gobblin.source.numWorkUnits.created" to be consistent with other metric names?




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



[GitHub] [incubator-gobblin] sv2000 commented on pull request #3076: [GOBBLIN-1230] add option to add spec executor configs to gaas job

Posted by GitBox <gi...@apache.org>.
sv2000 commented on pull request #3076:
URL: https://github.com/apache/incubator-gobblin/pull/3076#issuecomment-691339863






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



[GitHub] [incubator-gobblin] arjun4084346 commented on a change in pull request #3076: [GOBBLIN-1230] add option to add spec executor configs to gaas job

Posted by GitBox <gi...@apache.org>.
arjun4084346 commented on a change in pull request #3076:
URL: https://github.com/apache/incubator-gobblin/pull/3076#discussion_r487283604



##########
File path: gobblin-service/src/main/java/org/apache/gobblin/service/modules/spec/JobExecutionPlan.java
##########
@@ -165,6 +171,8 @@ private static void addAdditionalConfig(JobSpec jobSpec, Config sysConfig) {
 
       Config config = jobSpec.getConfig().withFallback(ConfigUtils.getConfigOrEmpty(sysConfig, additionalConfigsPrefix));
 
+      config = config.withFallback(ConfigUtils.getConfigOrEmpty(specExecutorConfig, additionalConfigsPrefix));

Review comment:
       It will be dropped, i.e. will return b

##########
File path: gobblin-metrics-libs/gobblin-metrics-base/src/main/java/org/apache/gobblin/metrics/MetricNames.java
##########
@@ -22,6 +22,8 @@
  */
 public class MetricNames {
 
+  public static final String NUM_WORKUNITS = "numWorkUnits";

Review comment:
       Are you suggesting a new class SourceMetrics ?

##########
File path: gobblin-runtime/src/main/java/org/apache/gobblin/runtime/AbstractJobLauncher.java
##########
@@ -414,6 +415,9 @@ public void apply(JobListener jobListener, JobContext jobContext)
         workUnitsCreationTimer.stop(this.eventMetadataGenerator.getMetadata(this.jobContext,
             EventName.WORK_UNITS_CREATION));
 
+        this.jobContext.getJobState().setProp(
+            MetricNames.NUM_WORKUNITS, workUnitStream.getMaterializedWorkUnitCollection().size());

Review comment:
       Right, it's not a codahale metric name. Can you suggest a right place? The current class (AbstractJobLauncher) ?




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



[GitHub] [incubator-gobblin] arjun4084346 commented on a change in pull request #3076: [GOBBLIN-1230] add option to add spec executor configs to gaas job

Posted by GitBox <gi...@apache.org>.
arjun4084346 commented on a change in pull request #3076:
URL: https://github.com/apache/incubator-gobblin/pull/3076#discussion_r487283604



##########
File path: gobblin-service/src/main/java/org/apache/gobblin/service/modules/spec/JobExecutionPlan.java
##########
@@ -165,6 +171,8 @@ private static void addAdditionalConfig(JobSpec jobSpec, Config sysConfig) {
 
       Config config = jobSpec.getConfig().withFallback(ConfigUtils.getConfigOrEmpty(sysConfig, additionalConfigsPrefix));
 
+      config = config.withFallback(ConfigUtils.getConfigOrEmpty(specExecutorConfig, additionalConfigsPrefix));

Review comment:
       It will be dropped, i.e. will return b

##########
File path: gobblin-metrics-libs/gobblin-metrics-base/src/main/java/org/apache/gobblin/metrics/MetricNames.java
##########
@@ -22,6 +22,8 @@
  */
 public class MetricNames {
 
+  public static final String NUM_WORKUNITS = "numWorkUnits";

Review comment:
       Are you suggesting a new class SourceMetrics ?

##########
File path: gobblin-runtime/src/main/java/org/apache/gobblin/runtime/AbstractJobLauncher.java
##########
@@ -414,6 +415,9 @@ public void apply(JobListener jobListener, JobContext jobContext)
         workUnitsCreationTimer.stop(this.eventMetadataGenerator.getMetadata(this.jobContext,
             EventName.WORK_UNITS_CREATION));
 
+        this.jobContext.getJobState().setProp(
+            MetricNames.NUM_WORKUNITS, workUnitStream.getMaterializedWorkUnitCollection().size());

Review comment:
       Right, it's not a codahale metric name. Can you suggest a right place? The current class (AbstractJobLauncher) ?

##########
File path: gobblin-service/src/main/java/org/apache/gobblin/service/modules/spec/JobExecutionPlan.java
##########
@@ -165,6 +171,8 @@ private static void addAdditionalConfig(JobSpec jobSpec, Config sysConfig) {
 
       Config config = jobSpec.getConfig().withFallback(ConfigUtils.getConfigOrEmpty(sysConfig, additionalConfigsPrefix));
 
+      config = config.withFallback(ConfigUtils.getConfigOrEmpty(specExecutorConfig, additionalConfigsPrefix));

Review comment:
       It will be dropped, i.e. will return b

##########
File path: gobblin-metrics-libs/gobblin-metrics-base/src/main/java/org/apache/gobblin/metrics/MetricNames.java
##########
@@ -22,6 +22,8 @@
  */
 public class MetricNames {
 
+  public static final String NUM_WORKUNITS = "numWorkUnits";

Review comment:
       Are you suggesting a new class SourceMetrics ?

##########
File path: gobblin-runtime/src/main/java/org/apache/gobblin/runtime/AbstractJobLauncher.java
##########
@@ -414,6 +415,9 @@ public void apply(JobListener jobListener, JobContext jobContext)
         workUnitsCreationTimer.stop(this.eventMetadataGenerator.getMetadata(this.jobContext,
             EventName.WORK_UNITS_CREATION));
 
+        this.jobContext.getJobState().setProp(
+            MetricNames.NUM_WORKUNITS, workUnitStream.getMaterializedWorkUnitCollection().size());

Review comment:
       Right, it's not a codahale metric name. Can you suggest a right place? The current class (AbstractJobLauncher) ?

##########
File path: gobblin-service/src/main/java/org/apache/gobblin/service/modules/spec/JobExecutionPlan.java
##########
@@ -165,6 +171,8 @@ private static void addAdditionalConfig(JobSpec jobSpec, Config sysConfig) {
 
       Config config = jobSpec.getConfig().withFallback(ConfigUtils.getConfigOrEmpty(sysConfig, additionalConfigsPrefix));
 
+      config = config.withFallback(ConfigUtils.getConfigOrEmpty(specExecutorConfig, additionalConfigsPrefix));

Review comment:
       It will be dropped, i.e. will return b

##########
File path: gobblin-metrics-libs/gobblin-metrics-base/src/main/java/org/apache/gobblin/metrics/MetricNames.java
##########
@@ -22,6 +22,8 @@
  */
 public class MetricNames {
 
+  public static final String NUM_WORKUNITS = "numWorkUnits";

Review comment:
       Are you suggesting a new class SourceMetrics ?

##########
File path: gobblin-runtime/src/main/java/org/apache/gobblin/runtime/AbstractJobLauncher.java
##########
@@ -414,6 +415,9 @@ public void apply(JobListener jobListener, JobContext jobContext)
         workUnitsCreationTimer.stop(this.eventMetadataGenerator.getMetadata(this.jobContext,
             EventName.WORK_UNITS_CREATION));
 
+        this.jobContext.getJobState().setProp(
+            MetricNames.NUM_WORKUNITS, workUnitStream.getMaterializedWorkUnitCollection().size());

Review comment:
       Right, it's not a codahale metric name. Can you suggest a right place? The current class (AbstractJobLauncher) ?

##########
File path: gobblin-service/src/main/java/org/apache/gobblin/service/modules/spec/JobExecutionPlan.java
##########
@@ -165,6 +171,8 @@ private static void addAdditionalConfig(JobSpec jobSpec, Config sysConfig) {
 
       Config config = jobSpec.getConfig().withFallback(ConfigUtils.getConfigOrEmpty(sysConfig, additionalConfigsPrefix));
 
+      config = config.withFallback(ConfigUtils.getConfigOrEmpty(specExecutorConfig, additionalConfigsPrefix));

Review comment:
       It will be dropped, i.e. will return b

##########
File path: gobblin-metrics-libs/gobblin-metrics-base/src/main/java/org/apache/gobblin/metrics/MetricNames.java
##########
@@ -22,6 +22,8 @@
  */
 public class MetricNames {
 
+  public static final String NUM_WORKUNITS = "numWorkUnits";

Review comment:
       Are you suggesting a new class SourceMetrics ?

##########
File path: gobblin-runtime/src/main/java/org/apache/gobblin/runtime/AbstractJobLauncher.java
##########
@@ -414,6 +415,9 @@ public void apply(JobListener jobListener, JobContext jobContext)
         workUnitsCreationTimer.stop(this.eventMetadataGenerator.getMetadata(this.jobContext,
             EventName.WORK_UNITS_CREATION));
 
+        this.jobContext.getJobState().setProp(
+            MetricNames.NUM_WORKUNITS, workUnitStream.getMaterializedWorkUnitCollection().size());

Review comment:
       Right, it's not a codahale metric name. Can you suggest a right place? The current class (AbstractJobLauncher) ?

##########
File path: gobblin-service/src/main/java/org/apache/gobblin/service/modules/spec/JobExecutionPlan.java
##########
@@ -165,6 +171,8 @@ private static void addAdditionalConfig(JobSpec jobSpec, Config sysConfig) {
 
       Config config = jobSpec.getConfig().withFallback(ConfigUtils.getConfigOrEmpty(sysConfig, additionalConfigsPrefix));
 
+      config = config.withFallback(ConfigUtils.getConfigOrEmpty(specExecutorConfig, additionalConfigsPrefix));

Review comment:
       It will be dropped, i.e. will return b

##########
File path: gobblin-metrics-libs/gobblin-metrics-base/src/main/java/org/apache/gobblin/metrics/MetricNames.java
##########
@@ -22,6 +22,8 @@
  */
 public class MetricNames {
 
+  public static final String NUM_WORKUNITS = "numWorkUnits";

Review comment:
       Are you suggesting a new class SourceMetrics ?

##########
File path: gobblin-runtime/src/main/java/org/apache/gobblin/runtime/AbstractJobLauncher.java
##########
@@ -414,6 +415,9 @@ public void apply(JobListener jobListener, JobContext jobContext)
         workUnitsCreationTimer.stop(this.eventMetadataGenerator.getMetadata(this.jobContext,
             EventName.WORK_UNITS_CREATION));
 
+        this.jobContext.getJobState().setProp(
+            MetricNames.NUM_WORKUNITS, workUnitStream.getMaterializedWorkUnitCollection().size());

Review comment:
       Right, it's not a codahale metric name. Can you suggest a right place? The current class (AbstractJobLauncher) ?

##########
File path: gobblin-service/src/main/java/org/apache/gobblin/service/modules/spec/JobExecutionPlan.java
##########
@@ -165,6 +171,8 @@ private static void addAdditionalConfig(JobSpec jobSpec, Config sysConfig) {
 
       Config config = jobSpec.getConfig().withFallback(ConfigUtils.getConfigOrEmpty(sysConfig, additionalConfigsPrefix));
 
+      config = config.withFallback(ConfigUtils.getConfigOrEmpty(specExecutorConfig, additionalConfigsPrefix));

Review comment:
       It will be dropped, i.e. will return b

##########
File path: gobblin-metrics-libs/gobblin-metrics-base/src/main/java/org/apache/gobblin/metrics/MetricNames.java
##########
@@ -22,6 +22,8 @@
  */
 public class MetricNames {
 
+  public static final String NUM_WORKUNITS = "numWorkUnits";

Review comment:
       Are you suggesting a new class SourceMetrics ?

##########
File path: gobblin-runtime/src/main/java/org/apache/gobblin/runtime/AbstractJobLauncher.java
##########
@@ -414,6 +415,9 @@ public void apply(JobListener jobListener, JobContext jobContext)
         workUnitsCreationTimer.stop(this.eventMetadataGenerator.getMetadata(this.jobContext,
             EventName.WORK_UNITS_CREATION));
 
+        this.jobContext.getJobState().setProp(
+            MetricNames.NUM_WORKUNITS, workUnitStream.getMaterializedWorkUnitCollection().size());

Review comment:
       Right, it's not a codahale metric name. Can you suggest a right place? The current class (AbstractJobLauncher) ?

##########
File path: gobblin-service/src/main/java/org/apache/gobblin/service/modules/spec/JobExecutionPlan.java
##########
@@ -165,6 +171,8 @@ private static void addAdditionalConfig(JobSpec jobSpec, Config sysConfig) {
 
       Config config = jobSpec.getConfig().withFallback(ConfigUtils.getConfigOrEmpty(sysConfig, additionalConfigsPrefix));
 
+      config = config.withFallback(ConfigUtils.getConfigOrEmpty(specExecutorConfig, additionalConfigsPrefix));

Review comment:
       It will be dropped, i.e. will return b

##########
File path: gobblin-metrics-libs/gobblin-metrics-base/src/main/java/org/apache/gobblin/metrics/MetricNames.java
##########
@@ -22,6 +22,8 @@
  */
 public class MetricNames {
 
+  public static final String NUM_WORKUNITS = "numWorkUnits";

Review comment:
       Are you suggesting a new class SourceMetrics ?

##########
File path: gobblin-runtime/src/main/java/org/apache/gobblin/runtime/AbstractJobLauncher.java
##########
@@ -414,6 +415,9 @@ public void apply(JobListener jobListener, JobContext jobContext)
         workUnitsCreationTimer.stop(this.eventMetadataGenerator.getMetadata(this.jobContext,
             EventName.WORK_UNITS_CREATION));
 
+        this.jobContext.getJobState().setProp(
+            MetricNames.NUM_WORKUNITS, workUnitStream.getMaterializedWorkUnitCollection().size());

Review comment:
       Right, it's not a codahale metric name. Can you suggest a right place? The current class (AbstractJobLauncher) ?




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



[GitHub] [incubator-gobblin] arjun4084346 commented on a change in pull request #3076: [GOBBLIN-1230] add option to add spec executor configs to gaas job

Posted by GitBox <gi...@apache.org>.
arjun4084346 commented on a change in pull request #3076:
URL: https://github.com/apache/incubator-gobblin/pull/3076#discussion_r487283604



##########
File path: gobblin-service/src/main/java/org/apache/gobblin/service/modules/spec/JobExecutionPlan.java
##########
@@ -165,6 +171,8 @@ private static void addAdditionalConfig(JobSpec jobSpec, Config sysConfig) {
 
       Config config = jobSpec.getConfig().withFallback(ConfigUtils.getConfigOrEmpty(sysConfig, additionalConfigsPrefix));
 
+      config = config.withFallback(ConfigUtils.getConfigOrEmpty(specExecutorConfig, additionalConfigsPrefix));

Review comment:
       It will be dropped, i.e. will return b

##########
File path: gobblin-metrics-libs/gobblin-metrics-base/src/main/java/org/apache/gobblin/metrics/MetricNames.java
##########
@@ -22,6 +22,8 @@
  */
 public class MetricNames {
 
+  public static final String NUM_WORKUNITS = "numWorkUnits";

Review comment:
       Are you suggesting a new class SourceMetrics ?

##########
File path: gobblin-runtime/src/main/java/org/apache/gobblin/runtime/AbstractJobLauncher.java
##########
@@ -414,6 +415,9 @@ public void apply(JobListener jobListener, JobContext jobContext)
         workUnitsCreationTimer.stop(this.eventMetadataGenerator.getMetadata(this.jobContext,
             EventName.WORK_UNITS_CREATION));
 
+        this.jobContext.getJobState().setProp(
+            MetricNames.NUM_WORKUNITS, workUnitStream.getMaterializedWorkUnitCollection().size());

Review comment:
       Right, it's not a codahale metric name. Can you suggest a right place? The current class (AbstractJobLauncher) ?




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



[GitHub] [incubator-gobblin] sv2000 commented on a change in pull request #3076: [GOBBLIN-1230] add option to add spec executor configs to gaas job

Posted by GitBox <gi...@apache.org>.
sv2000 commented on a change in pull request #3076:
URL: https://github.com/apache/incubator-gobblin/pull/3076#discussion_r487321615



##########
File path: gobblin-runtime/src/main/java/org/apache/gobblin/runtime/AbstractJobLauncher.java
##########
@@ -414,6 +415,9 @@ public void apply(JobListener jobListener, JobContext jobContext)
         workUnitsCreationTimer.stop(this.eventMetadataGenerator.getMetadata(this.jobContext,
             EventName.WORK_UNITS_CREATION));
 
+        this.jobContext.getJobState().setProp(
+            MetricNames.NUM_WORKUNITS, workUnitStream.getMaterializedWorkUnitCollection().size());

Review comment:
       On second reading - Is numWorkunits a CodaHale metric that gets emitted via MetricReporter? I think the metrics listed in MetricNames are intended for the reporter metrics. If numWorkUnits is intended for a different purpose, let's not add it into MetricNames class. 




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



[GitHub] [incubator-gobblin] arjun4084346 commented on a change in pull request #3076: [GOBBLIN-1230] add option to add spec executor configs to gaas job

Posted by GitBox <gi...@apache.org>.
arjun4084346 commented on a change in pull request #3076:
URL: https://github.com/apache/incubator-gobblin/pull/3076#discussion_r487415724



##########
File path: gobblin-metrics-libs/gobblin-metrics-base/src/main/java/org/apache/gobblin/metrics/MetricNames.java
##########
@@ -22,6 +22,8 @@
  */
 public class MetricNames {
 
+  public static final String NUM_WORKUNITS = "numWorkUnits";

Review comment:
       Are you suggesting a new class SourceMetrics ?




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



[GitHub] [incubator-gobblin] sv2000 commented on pull request #3076: [GOBBLIN-1230] add option to add spec executor configs to gaas job

Posted by GitBox <gi...@apache.org>.
sv2000 commented on pull request #3076:
URL: https://github.com/apache/incubator-gobblin/pull/3076#issuecomment-691339863






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



[GitHub] [incubator-gobblin] sv2000 commented on a change in pull request #3076: [GOBBLIN-1230] add option to add spec executor configs to gaas job

Posted by GitBox <gi...@apache.org>.
sv2000 commented on a change in pull request #3076:
URL: https://github.com/apache/incubator-gobblin/pull/3076#discussion_r487317913



##########
File path: gobblin-runtime/src/main/java/org/apache/gobblin/service/monitoring/JobStatus.java
##########
@@ -17,10 +17,11 @@
 
 package org.apache.gobblin.service.monitoring;
 
-import org.apache.gobblin.annotation.Alpha;
-
 import lombok.Builder;
 import lombok.Getter;
+import lombok.Setter;
+
+import org.apache.gobblin.annotation.Alpha;

Review comment:
       We can remove this annotation.

##########
File path: gobblin-service/src/main/java/org/apache/gobblin/service/modules/spec/JobExecutionPlan.java
##########
@@ -82,7 +87,8 @@ public JobExecutionPlan createPlan(FlowSpec flowSpec, Config jobConfig, SpecExec
      * @param flowSpec input FlowSpec.
      * @return a {@link JobSpec} corresponding to the resolved job config.
      */
-    private static JobSpec buildJobSpec(FlowSpec flowSpec, Config jobConfig, Long flowExecutionId, Config sysConfig) throws URISyntaxException {
+    private static JobSpec buildJobSpec(FlowSpec flowSpec, Config jobConfig, Long flowExecutionId, Config sysConfig, Config specExecutorConfig)

Review comment:
       Modify the javadoc to reflect the current list of arguments.

##########
File path: gobblin-service/src/main/java/org/apache/gobblin/service/modules/spec/JobExecutionPlan.java
##########
@@ -154,7 +160,7 @@ private static JobSpec buildJobSpec(FlowSpec flowSpec, Config jobConfig, Long fl
      * execution status of the job.
      * @param jobSpec representing a fully resolved {@link JobSpec}.
      */
-    private static void addAdditionalConfig(JobSpec jobSpec, Config sysConfig) {
+    private static void addAdditionalConfig(JobSpec jobSpec, Config sysConfig, Config specExecutorConfig) {

Review comment:
       Modify the javadoc.

##########
File path: gobblin-metrics-libs/gobblin-metrics-base/src/main/java/org/apache/gobblin/metrics/MetricNames.java
##########
@@ -22,6 +22,8 @@
  */
 public class MetricNames {
 
+  public static final String NUM_WORKUNITS = "numWorkUnits";

Review comment:
       Should this be grouped into SourceMetrics and have the metric name as "gobblin.source.numWorkUnits.created" to be consistent with other metric names?

##########
File path: gobblin-runtime/src/main/java/org/apache/gobblin/runtime/AbstractJobLauncher.java
##########
@@ -414,6 +415,9 @@ public void apply(JobListener jobListener, JobContext jobContext)
         workUnitsCreationTimer.stop(this.eventMetadataGenerator.getMetadata(this.jobContext,
             EventName.WORK_UNITS_CREATION));
 
+        this.jobContext.getJobState().setProp(
+            MetricNames.NUM_WORKUNITS, workUnitStream.getMaterializedWorkUnitCollection().size());

Review comment:
       On second reading - Is numWorkunits a CodaHale metric that gets emitted via MetricReporter? I think the metrics listed in MetricNames are intended for the reporter metrics. If numWorkUnits is intended for a different purpose, let's not add it into MetricNames class. 

##########
File path: gobblin-runtime/src/main/java/org/apache/gobblin/service/monitoring/JobStatus.java
##########
@@ -17,10 +17,11 @@
 
 package org.apache.gobblin.service.monitoring;
 
-import org.apache.gobblin.annotation.Alpha;
-
 import lombok.Builder;
 import lombok.Getter;
+import lombok.Setter;
+
+import org.apache.gobblin.annotation.Alpha;

Review comment:
       We can remove this annotation.

##########
File path: gobblin-service/src/main/java/org/apache/gobblin/service/modules/spec/JobExecutionPlan.java
##########
@@ -82,7 +87,8 @@ public JobExecutionPlan createPlan(FlowSpec flowSpec, Config jobConfig, SpecExec
      * @param flowSpec input FlowSpec.
      * @return a {@link JobSpec} corresponding to the resolved job config.
      */
-    private static JobSpec buildJobSpec(FlowSpec flowSpec, Config jobConfig, Long flowExecutionId, Config sysConfig) throws URISyntaxException {
+    private static JobSpec buildJobSpec(FlowSpec flowSpec, Config jobConfig, Long flowExecutionId, Config sysConfig, Config specExecutorConfig)

Review comment:
       Modify the javadoc to reflect the current list of arguments.

##########
File path: gobblin-service/src/main/java/org/apache/gobblin/service/modules/spec/JobExecutionPlan.java
##########
@@ -154,7 +160,7 @@ private static JobSpec buildJobSpec(FlowSpec flowSpec, Config jobConfig, Long fl
      * execution status of the job.
      * @param jobSpec representing a fully resolved {@link JobSpec}.
      */
-    private static void addAdditionalConfig(JobSpec jobSpec, Config sysConfig) {
+    private static void addAdditionalConfig(JobSpec jobSpec, Config sysConfig, Config specExecutorConfig) {

Review comment:
       Modify the javadoc.

##########
File path: gobblin-metrics-libs/gobblin-metrics-base/src/main/java/org/apache/gobblin/metrics/MetricNames.java
##########
@@ -22,6 +22,8 @@
  */
 public class MetricNames {
 
+  public static final String NUM_WORKUNITS = "numWorkUnits";

Review comment:
       Should this be grouped into SourceMetrics and have the metric name as "gobblin.source.numWorkUnits.created" to be consistent with other metric names?

##########
File path: gobblin-runtime/src/main/java/org/apache/gobblin/runtime/AbstractJobLauncher.java
##########
@@ -414,6 +415,9 @@ public void apply(JobListener jobListener, JobContext jobContext)
         workUnitsCreationTimer.stop(this.eventMetadataGenerator.getMetadata(this.jobContext,
             EventName.WORK_UNITS_CREATION));
 
+        this.jobContext.getJobState().setProp(
+            MetricNames.NUM_WORKUNITS, workUnitStream.getMaterializedWorkUnitCollection().size());

Review comment:
       On second reading - Is numWorkunits a CodaHale metric that gets emitted via MetricReporter? I think the metrics listed in MetricNames are intended for the reporter metrics. If numWorkUnits is intended for a different purpose, let's not add it into MetricNames class. 

##########
File path: gobblin-runtime/src/main/java/org/apache/gobblin/service/monitoring/JobStatus.java
##########
@@ -17,10 +17,11 @@
 
 package org.apache.gobblin.service.monitoring;
 
-import org.apache.gobblin.annotation.Alpha;
-
 import lombok.Builder;
 import lombok.Getter;
+import lombok.Setter;
+
+import org.apache.gobblin.annotation.Alpha;

Review comment:
       We can remove this annotation.

##########
File path: gobblin-service/src/main/java/org/apache/gobblin/service/modules/spec/JobExecutionPlan.java
##########
@@ -82,7 +87,8 @@ public JobExecutionPlan createPlan(FlowSpec flowSpec, Config jobConfig, SpecExec
      * @param flowSpec input FlowSpec.
      * @return a {@link JobSpec} corresponding to the resolved job config.
      */
-    private static JobSpec buildJobSpec(FlowSpec flowSpec, Config jobConfig, Long flowExecutionId, Config sysConfig) throws URISyntaxException {
+    private static JobSpec buildJobSpec(FlowSpec flowSpec, Config jobConfig, Long flowExecutionId, Config sysConfig, Config specExecutorConfig)

Review comment:
       Modify the javadoc to reflect the current list of arguments.

##########
File path: gobblin-service/src/main/java/org/apache/gobblin/service/modules/spec/JobExecutionPlan.java
##########
@@ -154,7 +160,7 @@ private static JobSpec buildJobSpec(FlowSpec flowSpec, Config jobConfig, Long fl
      * execution status of the job.
      * @param jobSpec representing a fully resolved {@link JobSpec}.
      */
-    private static void addAdditionalConfig(JobSpec jobSpec, Config sysConfig) {
+    private static void addAdditionalConfig(JobSpec jobSpec, Config sysConfig, Config specExecutorConfig) {

Review comment:
       Modify the javadoc.

##########
File path: gobblin-metrics-libs/gobblin-metrics-base/src/main/java/org/apache/gobblin/metrics/MetricNames.java
##########
@@ -22,6 +22,8 @@
  */
 public class MetricNames {
 
+  public static final String NUM_WORKUNITS = "numWorkUnits";

Review comment:
       Should this be grouped into SourceMetrics and have the metric name as "gobblin.source.numWorkUnits.created" to be consistent with other metric names?

##########
File path: gobblin-runtime/src/main/java/org/apache/gobblin/runtime/AbstractJobLauncher.java
##########
@@ -414,6 +415,9 @@ public void apply(JobListener jobListener, JobContext jobContext)
         workUnitsCreationTimer.stop(this.eventMetadataGenerator.getMetadata(this.jobContext,
             EventName.WORK_UNITS_CREATION));
 
+        this.jobContext.getJobState().setProp(
+            MetricNames.NUM_WORKUNITS, workUnitStream.getMaterializedWorkUnitCollection().size());

Review comment:
       On second reading - Is numWorkunits a CodaHale metric that gets emitted via MetricReporter? I think the metrics listed in MetricNames are intended for the reporter metrics. If numWorkUnits is intended for a different purpose, let's not add it into MetricNames class. 

##########
File path: gobblin-runtime/src/main/java/org/apache/gobblin/service/monitoring/JobStatus.java
##########
@@ -17,10 +17,11 @@
 
 package org.apache.gobblin.service.monitoring;
 
-import org.apache.gobblin.annotation.Alpha;
-
 import lombok.Builder;
 import lombok.Getter;
+import lombok.Setter;
+
+import org.apache.gobblin.annotation.Alpha;

Review comment:
       We can remove this annotation.

##########
File path: gobblin-service/src/main/java/org/apache/gobblin/service/modules/spec/JobExecutionPlan.java
##########
@@ -82,7 +87,8 @@ public JobExecutionPlan createPlan(FlowSpec flowSpec, Config jobConfig, SpecExec
      * @param flowSpec input FlowSpec.
      * @return a {@link JobSpec} corresponding to the resolved job config.
      */
-    private static JobSpec buildJobSpec(FlowSpec flowSpec, Config jobConfig, Long flowExecutionId, Config sysConfig) throws URISyntaxException {
+    private static JobSpec buildJobSpec(FlowSpec flowSpec, Config jobConfig, Long flowExecutionId, Config sysConfig, Config specExecutorConfig)

Review comment:
       Modify the javadoc to reflect the current list of arguments.

##########
File path: gobblin-service/src/main/java/org/apache/gobblin/service/modules/spec/JobExecutionPlan.java
##########
@@ -154,7 +160,7 @@ private static JobSpec buildJobSpec(FlowSpec flowSpec, Config jobConfig, Long fl
      * execution status of the job.
      * @param jobSpec representing a fully resolved {@link JobSpec}.
      */
-    private static void addAdditionalConfig(JobSpec jobSpec, Config sysConfig) {
+    private static void addAdditionalConfig(JobSpec jobSpec, Config sysConfig, Config specExecutorConfig) {

Review comment:
       Modify the javadoc.

##########
File path: gobblin-metrics-libs/gobblin-metrics-base/src/main/java/org/apache/gobblin/metrics/MetricNames.java
##########
@@ -22,6 +22,8 @@
  */
 public class MetricNames {
 
+  public static final String NUM_WORKUNITS = "numWorkUnits";

Review comment:
       Should this be grouped into SourceMetrics and have the metric name as "gobblin.source.numWorkUnits.created" to be consistent with other metric names?

##########
File path: gobblin-runtime/src/main/java/org/apache/gobblin/runtime/AbstractJobLauncher.java
##########
@@ -414,6 +415,9 @@ public void apply(JobListener jobListener, JobContext jobContext)
         workUnitsCreationTimer.stop(this.eventMetadataGenerator.getMetadata(this.jobContext,
             EventName.WORK_UNITS_CREATION));
 
+        this.jobContext.getJobState().setProp(
+            MetricNames.NUM_WORKUNITS, workUnitStream.getMaterializedWorkUnitCollection().size());

Review comment:
       On second reading - Is numWorkunits a CodaHale metric that gets emitted via MetricReporter? I think the metrics listed in MetricNames are intended for the reporter metrics. If numWorkUnits is intended for a different purpose, let's not add it into MetricNames class. 

##########
File path: gobblin-runtime/src/main/java/org/apache/gobblin/service/monitoring/JobStatus.java
##########
@@ -17,10 +17,11 @@
 
 package org.apache.gobblin.service.monitoring;
 
-import org.apache.gobblin.annotation.Alpha;
-
 import lombok.Builder;
 import lombok.Getter;
+import lombok.Setter;
+
+import org.apache.gobblin.annotation.Alpha;

Review comment:
       We can remove this annotation.

##########
File path: gobblin-service/src/main/java/org/apache/gobblin/service/modules/spec/JobExecutionPlan.java
##########
@@ -82,7 +87,8 @@ public JobExecutionPlan createPlan(FlowSpec flowSpec, Config jobConfig, SpecExec
      * @param flowSpec input FlowSpec.
      * @return a {@link JobSpec} corresponding to the resolved job config.
      */
-    private static JobSpec buildJobSpec(FlowSpec flowSpec, Config jobConfig, Long flowExecutionId, Config sysConfig) throws URISyntaxException {
+    private static JobSpec buildJobSpec(FlowSpec flowSpec, Config jobConfig, Long flowExecutionId, Config sysConfig, Config specExecutorConfig)

Review comment:
       Modify the javadoc to reflect the current list of arguments.

##########
File path: gobblin-service/src/main/java/org/apache/gobblin/service/modules/spec/JobExecutionPlan.java
##########
@@ -154,7 +160,7 @@ private static JobSpec buildJobSpec(FlowSpec flowSpec, Config jobConfig, Long fl
      * execution status of the job.
      * @param jobSpec representing a fully resolved {@link JobSpec}.
      */
-    private static void addAdditionalConfig(JobSpec jobSpec, Config sysConfig) {
+    private static void addAdditionalConfig(JobSpec jobSpec, Config sysConfig, Config specExecutorConfig) {

Review comment:
       Modify the javadoc.

##########
File path: gobblin-metrics-libs/gobblin-metrics-base/src/main/java/org/apache/gobblin/metrics/MetricNames.java
##########
@@ -22,6 +22,8 @@
  */
 public class MetricNames {
 
+  public static final String NUM_WORKUNITS = "numWorkUnits";

Review comment:
       Should this be grouped into SourceMetrics and have the metric name as "gobblin.source.numWorkUnits.created" to be consistent with other metric names?

##########
File path: gobblin-runtime/src/main/java/org/apache/gobblin/runtime/AbstractJobLauncher.java
##########
@@ -414,6 +415,9 @@ public void apply(JobListener jobListener, JobContext jobContext)
         workUnitsCreationTimer.stop(this.eventMetadataGenerator.getMetadata(this.jobContext,
             EventName.WORK_UNITS_CREATION));
 
+        this.jobContext.getJobState().setProp(
+            MetricNames.NUM_WORKUNITS, workUnitStream.getMaterializedWorkUnitCollection().size());

Review comment:
       On second reading - Is numWorkunits a CodaHale metric that gets emitted via MetricReporter? I think the metrics listed in MetricNames are intended for the reporter metrics. If numWorkUnits is intended for a different purpose, let's not add it into MetricNames class. 

##########
File path: gobblin-runtime/src/main/java/org/apache/gobblin/service/monitoring/JobStatus.java
##########
@@ -17,10 +17,11 @@
 
 package org.apache.gobblin.service.monitoring;
 
-import org.apache.gobblin.annotation.Alpha;
-
 import lombok.Builder;
 import lombok.Getter;
+import lombok.Setter;
+
+import org.apache.gobblin.annotation.Alpha;

Review comment:
       We can remove this annotation.

##########
File path: gobblin-service/src/main/java/org/apache/gobblin/service/modules/spec/JobExecutionPlan.java
##########
@@ -82,7 +87,8 @@ public JobExecutionPlan createPlan(FlowSpec flowSpec, Config jobConfig, SpecExec
      * @param flowSpec input FlowSpec.
      * @return a {@link JobSpec} corresponding to the resolved job config.
      */
-    private static JobSpec buildJobSpec(FlowSpec flowSpec, Config jobConfig, Long flowExecutionId, Config sysConfig) throws URISyntaxException {
+    private static JobSpec buildJobSpec(FlowSpec flowSpec, Config jobConfig, Long flowExecutionId, Config sysConfig, Config specExecutorConfig)

Review comment:
       Modify the javadoc to reflect the current list of arguments.

##########
File path: gobblin-service/src/main/java/org/apache/gobblin/service/modules/spec/JobExecutionPlan.java
##########
@@ -154,7 +160,7 @@ private static JobSpec buildJobSpec(FlowSpec flowSpec, Config jobConfig, Long fl
      * execution status of the job.
      * @param jobSpec representing a fully resolved {@link JobSpec}.
      */
-    private static void addAdditionalConfig(JobSpec jobSpec, Config sysConfig) {
+    private static void addAdditionalConfig(JobSpec jobSpec, Config sysConfig, Config specExecutorConfig) {

Review comment:
       Modify the javadoc.

##########
File path: gobblin-metrics-libs/gobblin-metrics-base/src/main/java/org/apache/gobblin/metrics/MetricNames.java
##########
@@ -22,6 +22,8 @@
  */
 public class MetricNames {
 
+  public static final String NUM_WORKUNITS = "numWorkUnits";

Review comment:
       Should this be grouped into SourceMetrics and have the metric name as "gobblin.source.numWorkUnits.created" to be consistent with other metric names?

##########
File path: gobblin-runtime/src/main/java/org/apache/gobblin/runtime/AbstractJobLauncher.java
##########
@@ -414,6 +415,9 @@ public void apply(JobListener jobListener, JobContext jobContext)
         workUnitsCreationTimer.stop(this.eventMetadataGenerator.getMetadata(this.jobContext,
             EventName.WORK_UNITS_CREATION));
 
+        this.jobContext.getJobState().setProp(
+            MetricNames.NUM_WORKUNITS, workUnitStream.getMaterializedWorkUnitCollection().size());

Review comment:
       On second reading - Is numWorkunits a CodaHale metric that gets emitted via MetricReporter? I think the metrics listed in MetricNames are intended for the reporter metrics. If numWorkUnits is intended for a different purpose, let's not add it into MetricNames class. 

##########
File path: gobblin-runtime/src/main/java/org/apache/gobblin/service/monitoring/JobStatus.java
##########
@@ -17,10 +17,11 @@
 
 package org.apache.gobblin.service.monitoring;
 
-import org.apache.gobblin.annotation.Alpha;
-
 import lombok.Builder;
 import lombok.Getter;
+import lombok.Setter;
+
+import org.apache.gobblin.annotation.Alpha;

Review comment:
       We can remove this annotation.

##########
File path: gobblin-service/src/main/java/org/apache/gobblin/service/modules/spec/JobExecutionPlan.java
##########
@@ -82,7 +87,8 @@ public JobExecutionPlan createPlan(FlowSpec flowSpec, Config jobConfig, SpecExec
      * @param flowSpec input FlowSpec.
      * @return a {@link JobSpec} corresponding to the resolved job config.
      */
-    private static JobSpec buildJobSpec(FlowSpec flowSpec, Config jobConfig, Long flowExecutionId, Config sysConfig) throws URISyntaxException {
+    private static JobSpec buildJobSpec(FlowSpec flowSpec, Config jobConfig, Long flowExecutionId, Config sysConfig, Config specExecutorConfig)

Review comment:
       Modify the javadoc to reflect the current list of arguments.

##########
File path: gobblin-service/src/main/java/org/apache/gobblin/service/modules/spec/JobExecutionPlan.java
##########
@@ -154,7 +160,7 @@ private static JobSpec buildJobSpec(FlowSpec flowSpec, Config jobConfig, Long fl
      * execution status of the job.
      * @param jobSpec representing a fully resolved {@link JobSpec}.
      */
-    private static void addAdditionalConfig(JobSpec jobSpec, Config sysConfig) {
+    private static void addAdditionalConfig(JobSpec jobSpec, Config sysConfig, Config specExecutorConfig) {

Review comment:
       Modify the javadoc.

##########
File path: gobblin-metrics-libs/gobblin-metrics-base/src/main/java/org/apache/gobblin/metrics/MetricNames.java
##########
@@ -22,6 +22,8 @@
  */
 public class MetricNames {
 
+  public static final String NUM_WORKUNITS = "numWorkUnits";

Review comment:
       Should this be grouped into SourceMetrics and have the metric name as "gobblin.source.numWorkUnits.created" to be consistent with other metric names?

##########
File path: gobblin-runtime/src/main/java/org/apache/gobblin/runtime/AbstractJobLauncher.java
##########
@@ -414,6 +415,9 @@ public void apply(JobListener jobListener, JobContext jobContext)
         workUnitsCreationTimer.stop(this.eventMetadataGenerator.getMetadata(this.jobContext,
             EventName.WORK_UNITS_CREATION));
 
+        this.jobContext.getJobState().setProp(
+            MetricNames.NUM_WORKUNITS, workUnitStream.getMaterializedWorkUnitCollection().size());

Review comment:
       On second reading - Is numWorkunits a CodaHale metric that gets emitted via MetricReporter? I think the metrics listed in MetricNames are intended for the reporter metrics. If numWorkUnits is intended for a different purpose, let's not add it into MetricNames class. 

##########
File path: gobblin-runtime/src/main/java/org/apache/gobblin/service/monitoring/JobStatus.java
##########
@@ -17,10 +17,11 @@
 
 package org.apache.gobblin.service.monitoring;
 
-import org.apache.gobblin.annotation.Alpha;
-
 import lombok.Builder;
 import lombok.Getter;
+import lombok.Setter;
+
+import org.apache.gobblin.annotation.Alpha;

Review comment:
       We can remove this annotation.

##########
File path: gobblin-service/src/main/java/org/apache/gobblin/service/modules/spec/JobExecutionPlan.java
##########
@@ -82,7 +87,8 @@ public JobExecutionPlan createPlan(FlowSpec flowSpec, Config jobConfig, SpecExec
      * @param flowSpec input FlowSpec.
      * @return a {@link JobSpec} corresponding to the resolved job config.
      */
-    private static JobSpec buildJobSpec(FlowSpec flowSpec, Config jobConfig, Long flowExecutionId, Config sysConfig) throws URISyntaxException {
+    private static JobSpec buildJobSpec(FlowSpec flowSpec, Config jobConfig, Long flowExecutionId, Config sysConfig, Config specExecutorConfig)

Review comment:
       Modify the javadoc to reflect the current list of arguments.

##########
File path: gobblin-service/src/main/java/org/apache/gobblin/service/modules/spec/JobExecutionPlan.java
##########
@@ -154,7 +160,7 @@ private static JobSpec buildJobSpec(FlowSpec flowSpec, Config jobConfig, Long fl
      * execution status of the job.
      * @param jobSpec representing a fully resolved {@link JobSpec}.
      */
-    private static void addAdditionalConfig(JobSpec jobSpec, Config sysConfig) {
+    private static void addAdditionalConfig(JobSpec jobSpec, Config sysConfig, Config specExecutorConfig) {

Review comment:
       Modify the javadoc.

##########
File path: gobblin-metrics-libs/gobblin-metrics-base/src/main/java/org/apache/gobblin/metrics/MetricNames.java
##########
@@ -22,6 +22,8 @@
  */
 public class MetricNames {
 
+  public static final String NUM_WORKUNITS = "numWorkUnits";

Review comment:
       Should this be grouped into SourceMetrics and have the metric name as "gobblin.source.numWorkUnits.created" to be consistent with other metric names?

##########
File path: gobblin-runtime/src/main/java/org/apache/gobblin/runtime/AbstractJobLauncher.java
##########
@@ -414,6 +415,9 @@ public void apply(JobListener jobListener, JobContext jobContext)
         workUnitsCreationTimer.stop(this.eventMetadataGenerator.getMetadata(this.jobContext,
             EventName.WORK_UNITS_CREATION));
 
+        this.jobContext.getJobState().setProp(
+            MetricNames.NUM_WORKUNITS, workUnitStream.getMaterializedWorkUnitCollection().size());

Review comment:
       On second reading - Is numWorkunits a CodaHale metric that gets emitted via MetricReporter? I think the metrics listed in MetricNames are intended for the reporter metrics. If numWorkUnits is intended for a different purpose, let's not add it into MetricNames class. 




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



[GitHub] [incubator-gobblin] sv2000 commented on a change in pull request #3076: [GOBBLIN-1230] add option to add spec executor configs to gaas job

Posted by GitBox <gi...@apache.org>.
sv2000 commented on a change in pull request #3076:
URL: https://github.com/apache/incubator-gobblin/pull/3076#discussion_r469605369



##########
File path: gobblin-service/src/main/java/org/apache/gobblin/service/modules/spec/JobExecutionPlan.java
##########
@@ -165,6 +171,8 @@ private static void addAdditionalConfig(JobSpec jobSpec, Config sysConfig) {
 
       Config config = jobSpec.getConfig().withFallback(ConfigUtils.getConfigOrEmpty(sysConfig, additionalConfigsPrefix));
 
+      config = config.withFallback(ConfigUtils.getConfigOrEmpty(specExecutorConfig, additionalConfigsPrefix));

Review comment:
       Will the prefix key be included in the config or will it be dropped? e.g. "specExecutor.a.b" and prefix is "a", will this return "a.b" or just "b"? 

##########
File path: gobblin-runtime/src/main/java/org/apache/gobblin/runtime/mapreduce/MRJobLauncher.java
##########
@@ -153,6 +153,7 @@
   public static final String MAPPER_TASK_ATTEMPT_NUM_KEY = ConfigurationKeys.METRICS_CONFIGURATIONS_PREFIX + "reporting.mapper.task.attempt.num";
   public static final String REDUCER_TASK_NUM_KEY = ConfigurationKeys.METRICS_CONFIGURATIONS_PREFIX + "reporting.reducer.task.num";
   public static final String REDUCER_TASK_ATTEMPT_NUM_KEY = ConfigurationKeys.METRICS_CONFIGURATIONS_PREFIX + "reporting.reducer.task.attempt.num";
+  public static final String NUM_MAPPERS = "numMappers";

Review comment:
       Where is this being used?




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