davsclaus commented on code in PR #28255:
URL: https://github.com/apache/camel/pull/28255#discussion_r4344925696
##########
components/camel-file/src/main/java/org/apache/camel/component/file/GenericFileKeptDoneFiles.java:
##########
@@ -59,8 +61,6 @@ synchronized List<String> startBatch(Set<String>
listedDoneFiles, boolean listin
}
}
kept.clear();
Review Comment:
Not blocking, older than this PR: this path has the same kind of window.
When the listing is complete, `kept.clear()` drops the done file here. The done
files of the files this poll leaves are kept again only later: in `poll()` for
the non-eager `maxMessagesPerPoll` cut (after the exchanges are created and
sorted), and in `processBatch` for files that are not started or are left when
the batch stops. If the last file of the previous poll completes asynchronously
in between (for example the route hands off to `threads()` or `seda`),
`GenericFileOnCompletion.handleDoneFile` sees the done file as not kept and
deletes it. The files this poll then leaves have no done file. The window is
longer than the one this PR removes, but it needs an async route. Worth a
follow-up JIRA rather than more changes here.
--
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]