924060929 commented on code in PR #68283:
URL: https://github.com/apache/doris/pull/68283#discussion_r4069820977


##########
fe/fe-core/src/main/java/org/apache/doris/nereids/trees/plans/commands/execute/ConnectorRewriteDriver.java:
##########
@@ -224,30 +223,63 @@ public void onTaskFailed(Long taskId, Exception error) {
             tasks.add(task);
         }
 
+        List<ConnectorRewriteGroupTask> submitted = Lists.newArrayList();
         try {
-            for (TransientTaskExecutor task : tasks) {
+            for (ConnectorRewriteGroupTask task : tasks) {
                 
Env.getCurrentEnv().getTransientTaskManager().addMemoryTask(task);
+                submitted.add(task);

Review Comment:
   Fixed at the source. `TransientTaskManager.addMemoryTask` now removes the 
task from `taskExecutorMap` when `tryPublishTask` fails, so the task whose 
event was never published is no longer retained for the FE lifetime, and 
`TaskDisruptor.tryPublishTask` now throws when the disruptor is closed instead 
of silently returning. Added 
`TransientTaskManagerTest.publicationFailureUnregistersTheRegisteredTask`, 
which performs the real map insertion and only stubs the publication to fail, 
plus `closedDisruptorFailsInsteadOfSilentlyDroppingTheTask` — both exercise the 
register-before-publish boundary the driver test mocked away.
   



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