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

davsclaus pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/camel.git

commit ce8bd681db8d0a2f68f8a2c48108976a850ac985
Author: Claus Ibsen <claus.ib...@gmail.com>
AuthorDate: Wed Apr 22 13:28:19 2020 +0200

    Fixed NPE in thread pool builder for nameless pools
---
 .../src/main/java/org/apache/camel/builder/ThreadPoolBuilder.java    | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git 
a/core/camel-core-engine/src/main/java/org/apache/camel/builder/ThreadPoolBuilder.java
 
b/core/camel-core-engine/src/main/java/org/apache/camel/builder/ThreadPoolBuilder.java
index d7b06ff..1d6f563 100644
--- 
a/core/camel-core-engine/src/main/java/org/apache/camel/builder/ThreadPoolBuilder.java
+++ 
b/core/camel-core-engine/src/main/java/org/apache/camel/builder/ThreadPoolBuilder.java
@@ -76,7 +76,8 @@ public final class ThreadPoolBuilder {
      * @throws Exception is thrown if error building the thread pool
      */
     public ExecutorService build() throws Exception {
-        return build(null, null);
+        // cannot use null name
+        return build(null, "ThreadPool");
     }
 
     /**
@@ -110,7 +111,7 @@ public final class ThreadPoolBuilder {
      * @throws Exception is thrown if error building the scheduled thread pool
      */
     public ScheduledExecutorService buildScheduled() throws Exception {
-        return buildScheduled(null, null);
+        return buildScheduled(null, "ScheduledThreadPool");
     }
 
     /**

Reply via email to