mohit-devlogs commented on code in PR #714:
URL: https://github.com/apache/wayang/pull/714#discussion_r3087063639


##########
wayang-platforms/wayang-jdbc-template/src/main/java/org/apache/wayang/jdbc/execution/JdbcExecutor.java:
##########
@@ -158,69 +183,84 @@ protected static Tuple2<String, SqlQueryChannel.Instance> 
createSqlQuery(final E
             final OptimizationContext context, final JdbcExecutor 
jdbcExecutor) {
         final Collection<?> startTasks = stage.getStartTasks();
         final Collection<?> termTasks = stage.getTerminalTasks();
-
         // Verify that we can handle this instance.
         assert startTasks.size() == 1 : "Invalid jdbc stage: multiple sources 
are not currently supported";
         final ExecutionTask startTask = (ExecutionTask) 
startTasks.toArray()[0];
         assert termTasks.size() == 1 : "Invalid JDBC stage: multiple terminal 
tasks are not currently supported.";
         final ExecutionTask termTask = (ExecutionTask) termTasks.toArray()[0];
         assert startTask.getOperator() instanceof TableSource
                 : "Invalid JDBC stage: Start task has to be a TableSource";
-
         // Extract the different types of ExecutionOperators from the stage.
         final JdbcTableSource tableOp = (JdbcTableSource) 
startTask.getOperator();
-        SqlQueryChannel.Instance tipChannelInstance = 
JdbcExecutor.instantiateOutboundChannel(startTask, context, jdbcExecutor);
+        SqlQueryChannel.Instance tipChannelInstance =
+                JdbcExecutor.instantiateOutboundChannel(startTask, context, 
jdbcExecutor);
+
         final Collection<JdbcFilterOperator> filterTasks = new ArrayList<>(4);
         JdbcProjectionOperator projectionTask = null;
         final Collection<JdbcJoinOperator<?>> joinTasks = new ArrayList<>();
+
         final Set<ExecutionTask> allTasks = stage.getAllTasks();
         assert allTasks.size() <= 3;
+
         ExecutionTask nextTask = 
JdbcExecutor.findJdbcExecutionOperatorTaskInStage(startTask, stage);
+
         while (nextTask != null) {
             // Evaluate the nextTask.
             if (nextTask.getOperator() instanceof final JdbcFilterOperator 
filterOperator) {
                 filterTasks.add(filterOperator);
             } else if (nextTask.getOperator() instanceof 
JdbcProjectionOperator projectionOperator) {
-                assert projectionTask == null; // Allow one projection 
operator per stage for now.
+                assert projectionTask == null;

Review Comment:
   Thanks for pointing this out. I have restored the missing comment.



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

Reply via email to