davsclaus opened a new pull request, #24745: URL: https://github.com/apache/camel/pull/24745
## Summary Fixes [CAMEL-24090](https://issues.apache.org/jira/browse/CAMEL-24090). With `idempotent=true` (implied by `noop=true`) and default `idempotentEager=true`, keys are added to the idempotent repository during directory scanning. If `pollDirectory` then throws (FTP disconnect mid-scan, I/O error, filter exception), the catch block in `GenericFileConsumer.poll()` drains via the **List overload** of `removeExcessiveInProgressFiles`, which only removes in-progress keys — the eagerly-added idempotent keys stay behind. Files are then permanently skipped on subsequent polls. CAMEL-21830 (commit `130bde60462b`) fixed the **Deque overload** used for batch draining but missed the List overload on the poll-exception path. ### Changes - **`GenericFileConsumer.java`**: Mirror the Deque overload — in the List drain, when `isIdempotentEager()` and an idempotent repository is configured, call `removeExcessiveIdempotentFile(file, null)`. - **`FileIdempotentEagerPollExceptionTest.java`**: New test that creates two files with `preSort=name` for deterministic ordering. A filter throws on the second file during the first poll only. Without the fix, the first file's idempotent key leaks and it is never consumed (test times out). With the fix, both files are consumed on subsequent polls. _Claude Code on behalf of davsclaus_ Co-Authored-By: Claude Opus 4.6 <[email protected]> -- 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]
