You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@shardingsphere.apache.org by GitBox <gi...@apache.org> on 2020/08/15 13:26:51 UTC

[GitHub] [shardingsphere-elasticjob] terrymanu commented on a change in pull request #1358: Add dag

terrymanu commented on a change in pull request #1358:
URL: https://github.com/apache/shardingsphere-elasticjob/pull/1358#discussion_r470976191



##########
File path: elasticjob-executor/elasticjob-executor-kernel/src/main/java/org/apache/shardingsphere/elasticjob/executor/ElasticJobExecutor.java
##########
@@ -86,6 +86,19 @@ public void execute() {
         } catch (final JobExecutionEnvironmentException cause) {
             jobErrorHandler.handleException(jobConfig.getJobName(), cause);
         }
+

Review comment:
       Please remove useless blank line

##########
File path: elasticjob-executor/elasticjob-executor-kernel/src/main/java/org/apache/shardingsphere/elasticjob/executor/ElasticJobExecutor.java
##########
@@ -86,6 +86,19 @@ public void execute() {
         } catch (final JobExecutionEnvironmentException cause) {
             jobErrorHandler.handleException(jobConfig.getJobName(), cause);
         }
+
+        if (jobFacade.isDagJob()) {
+            try {
+                jobFacade.dagStatesCheck();
+                jobFacade.dagJobDependenciesCheck();
+                //CHECKSTYLE:OFF
+            } catch (Exception e) {
+                //CHECKSTYLE:ON
+                log.error("DAG job - {} exception! Check !", jobConfig.getJobName(), e);

Review comment:
       Throw exception is better than log only if configuration error




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