You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@camel.apache.org by da...@apache.org on 2022/01/05 13:20:48 UTC

[camel] branch camel-3.14.x updated: [CAMEL-17425] camel-quartz - OSGi compatibility is broken for loading resources from classloader (#6654)

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

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


The following commit(s) were added to refs/heads/camel-3.14.x by this push:
     new 3bc6960  [CAMEL-17425] camel-quartz - OSGi compatibility is broken for loading resources from classloader (#6654)
3bc6960 is described below

commit 3bc696034a18954c9e9cb1cf0043c1e50e03b950
Author: François Papon <fp...@apache.org>
AuthorDate: Wed Jan 5 14:18:09 2022 +0100

    [CAMEL-17425] camel-quartz - OSGi compatibility is broken for loading resources from classloader (#6654)
---
 .../main/java/org/apache/camel/component/quartz/QuartzComponent.java    | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/components/camel-quartz/src/main/java/org/apache/camel/component/quartz/QuartzComponent.java b/components/camel-quartz/src/main/java/org/apache/camel/component/quartz/QuartzComponent.java
index ca361fa..9c43e28 100644
--- a/components/camel-quartz/src/main/java/org/apache/camel/component/quartz/QuartzComponent.java
+++ b/components/camel-quartz/src/main/java/org/apache/camel/component/quartz/QuartzComponent.java
@@ -246,7 +246,7 @@ public class QuartzComponent extends DefaultComponent implements ExtendedStartup
             // or setFactory(SchedulerFactory) methods
 
             // must use classloader from StdSchedulerFactory to work even in OSGi
-            InputStream is = org.apache.camel.util.ObjectHelper.loadResourceAsStream("org/quartz/quartz.properties");
+            InputStream is = StdSchedulerFactory.class.getClassLoader().getResourceAsStream("org/quartz/quartz.properties");
             if (is == null) {
                 throw new SchedulerException("Quartz properties file not found in classpath: org/quartz/quartz.properties");
             }