You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@camel.apache.org by ac...@apache.org on 2022/05/12 05:13:06 UTC
[camel] 02/03: (chores) Minor cosmetic change on camel-base-engine to make checkstyle happy (#7599)
This is an automated email from the ASF dual-hosted git repository.
acosentino pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/camel.git
commit 7a33814cb74844f6ed02e02e71c5143cd2d92db7
Author: Otavio Rodolfo Piske <or...@users.noreply.github.com>
AuthorDate: Thu May 12 06:31:09 2022 +0200
(chores) Minor cosmetic change on camel-base-engine to make checkstyle happy (#7599)
---
.../org/apache/camel/impl/engine/DefaultStreamCachingStrategy.java | 6 +++++-
1 file changed, 5 insertions(+), 1 deletion(-)
diff --git a/core/camel-base-engine/src/main/java/org/apache/camel/impl/engine/DefaultStreamCachingStrategy.java b/core/camel-base-engine/src/main/java/org/apache/camel/impl/engine/DefaultStreamCachingStrategy.java
index 88eb40a706d..0e418fe9808 100644
--- a/core/camel-base-engine/src/main/java/org/apache/camel/impl/engine/DefaultStreamCachingStrategy.java
+++ b/core/camel-base-engine/src/main/java/org/apache/camel/impl/engine/DefaultStreamCachingStrategy.java
@@ -347,7 +347,7 @@ public class DefaultStreamCachingStrategy extends ServiceSupport implements Came
@Override
protected void doStop() throws Exception {
- if (spoolEnabled && (spoolThreshold > 0 & spoolDirectory != null && isRemoveSpoolDirectoryWhenStopping())) {
+ if (spoolEnabled && isSpoolRemovable()) {
LOG.debug("Removing spool directory: {}", spoolDirectory);
FileUtil.removeDir(spoolDirectory);
}
@@ -359,6 +359,10 @@ public class DefaultStreamCachingStrategy extends ServiceSupport implements Came
statistics.reset();
}
+ private boolean isSpoolRemovable() {
+ return spoolThreshold > 0 & spoolDirectory != null && isRemoveSpoolDirectoryWhenStopping();
+ }
+
@Override
public String toString() {
return "DefaultStreamCachingStrategy["