This is an automated email from the ASF dual-hosted git repository. orpiske pushed a commit to branch main in repository https://gitbox.apache.org/repos/asf/camel.git
commit dc4036d58ef6b5b41c0cb51076c90aba75d64c04 Author: Otavio Rodolfo Piske <[email protected]> AuthorDate: Mon Jan 15 11:05:26 2024 +0100 CAMEL-20297 camel-mongodb: do not swallow interrupted exceptions --- .../apache/camel/component/mongodb/MongoAbstractConsumerThread.java | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/components/camel-mongodb/src/main/java/org/apache/camel/component/mongodb/MongoAbstractConsumerThread.java b/components/camel-mongodb/src/main/java/org/apache/camel/component/mongodb/MongoAbstractConsumerThread.java index 5af931a3808..ea2cca9dc0e 100644 --- a/components/camel-mongodb/src/main/java/org/apache/camel/component/mongodb/MongoAbstractConsumerThread.java +++ b/components/camel-mongodb/src/main/java/org/apache/camel/component/mongodb/MongoAbstractConsumerThread.java @@ -85,7 +85,9 @@ abstract class MongoAbstractConsumerThread implements Runnable { if (cursorRegenerationDelayEnabled) { try { Thread.sleep(cursorRegenerationDelay); - } catch (InterruptedException ignored) { + } catch (InterruptedException e) { + log.info("Interrupted while waiting for the cursor regeneration"); + Thread.currentThread().interrupt(); } }
