You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@inlong.apache.org by do...@apache.org on 2024/04/23 11:27:29 UTC

(inlong) 05/06: [INLONG-10047][Agent] Fix the bug in the logic for judging the completion status of the supplementary recording task (#10050)

This is an automated email from the ASF dual-hosted git repository.

dockerzhang pushed a commit to branch branch-1.12
in repository https://gitbox.apache.org/repos/asf/inlong.git

commit 5916eefd62eadb0dd0909aba7e6511c8e50868cd
Author: justinwwhuang <hw...@163.com>
AuthorDate: Tue Apr 23 18:32:41 2024 +0800

    [INLONG-10047][Agent] Fix the bug in the logic for judging the completion status of the supplementary recording task (#10050)
---
 .../main/java/org/apache/inlong/agent/plugin/task/file/LogFileTask.java | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/inlong-agent/agent-plugins/src/main/java/org/apache/inlong/agent/plugin/task/file/LogFileTask.java b/inlong-agent/agent-plugins/src/main/java/org/apache/inlong/agent/plugin/task/file/LogFileTask.java
index f06ac21f0a..4e6493c02a 100644
--- a/inlong-agent/agent-plugins/src/main/java/org/apache/inlong/agent/plugin/task/file/LogFileTask.java
+++ b/inlong-agent/agent-plugins/src/main/java/org/apache/inlong/agent/plugin/task/file/LogFileTask.java
@@ -236,7 +236,7 @@ public class LogFileTask extends AbstractTask {
             runAtLeastOneTime = true;
         }
         dealWithEventMap();
-        if (allInstanceFinished()) {
+        if (instanceQueue.isEmpty() && allInstanceFinished()) {
             LOGGER.info("retry task finished, send action to task manager, taskId {}", getTaskId());
             TaskAction action = new TaskAction(org.apache.inlong.agent.core.task.ActionType.FINISH, taskProfile);
             taskManager.submitAction(action);