cryptoe commented on code in PR #13062:
URL: https://github.com/apache/druid/pull/13062#discussion_r1005246893


##########
extensions-core/multi-stage-query/src/main/java/org/apache/druid/msq/exec/WorkerImpl.java:
##########
@@ -888,7 +895,33 @@ public void onSuccess(final List<Object> 
workerResultAndOutputChannelsResolved)
             for (OutputChannel channel : outputChannels.getAllChannels()) {
               stageOutputs.computeIfAbsent(stageDef.getId(), ignored1 -> new 
ConcurrentHashMap<>())
                           .computeIfAbsent(channel.getPartitionNumber(), 
ignored2 -> channel.getReadableChannel());
+
+            }
+
+            if (durableStageStorageEnabled) {
+              // Once the outputs channels have been resolved and are ready 
for reading, the worker appends the filename
+              // with a special marker flag and adds it to the
+              DurableStorageOutputChannelFactory 
durableStorageOutputChannelFactory =
+                  
DurableStorageOutputChannelFactory.createStandardImplementation(
+                      task.getControllerTaskId(),
+                      task().getWorkerNumber(),
+                      stageDef.getStageNumber(),
+                      task().getId(),
+                      frameContext.memoryParameters().getStandardFrameSize(),
+                      MSQTasks.makeStorageConnector(context.injector())
+                  );
+              try {
+                
durableStorageOutputChannelFactory.createSuccessFile(task.getId());
+              }
+              catch (IOException e) {
+                throw new ISE(
+                    e,
+                    "Unable to suffix the file with %s",

Review Comment:
   How about changing this to : "Unable to create the success file for task: xx 
, stage : yy , worker: zz" ? 



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


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to