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
The following commit(s) were added to refs/heads/master by this push: new 119a9b1 camel-health - Ups fix NPE 119a9b1 is described below commit 119a9b10ae34d9f3c8429885770488e92b1af7c3 Author: Claus Ibsen <claus.ib...@gmail.com> AuthorDate: Mon Jun 1 10:24:49 2020 +0200 camel-health - Ups fix NPE --- .../java/org/apache/camel/impl/engine/AbstractCamelContext.java | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/core/camel-base/src/main/java/org/apache/camel/impl/engine/AbstractCamelContext.java b/core/camel-base/src/main/java/org/apache/camel/impl/engine/AbstractCamelContext.java index 14f968f..a2f1503 100644 --- a/core/camel-base/src/main/java/org/apache/camel/impl/engine/AbstractCamelContext.java +++ b/core/camel-base/src/main/java/org/apache/camel/impl/engine/AbstractCamelContext.java @@ -2497,10 +2497,12 @@ public abstract class AbstractCamelContext extends BaseService // setup health-check registry as its needed this early phase for 3rd party to register custom repositories HealthCheckRegistry hcr = getExtension(HealthCheckRegistry.class); if (hcr == null) { - // install health-check registry if discovered from classpath hcr = createHealthCheckRegistry(); - hcr.setCamelContext(this); - setExtension(HealthCheckRegistry.class, hcr); + if (hcr != null) { + // install health-check registry if it was discovered from classpath (camel-health) + hcr.setCamelContext(this); + setExtension(HealthCheckRegistry.class, hcr); + } } // Call all registered trackers with this context