|
Hi all,
I switched from Apache Camel version 2.8.4 (in ServiceMix 4.4.1) to the most recent version 2.9.2. Resource loading in 2.8.4 worked well, but not in the new release of camel. I've a blueprint XML that contains the camel route deployed in the deploy folder as well as several osgi bundles that contain template resources for XSLT and String-Template. I get the following error: java.io.FileNotFoundException: Cannot find resource in classpath for URI: com/example/test.xml at org.apache.camel.util.ResourceHelper.resolveMandatoryResourceAsInputStream(ResourceHelper.java:89)[91:org.apache.camel.camel-core:2.9.2] at org.apache.camel.component.ResourceEndpoint.loadResource(ResourceEndpoint.java:92)[91:org.apache.camel.camel-core:2.9.2] at org.apache.camel.component.ResourceEndpoint.getResourceAsInputStreamWithoutCache(ResourceEndpoint.java:81)[91:org.apache.camel.camel-core:2.9.2] at org.apache.camel.component.ResourceEndpoint.getResourceAsInputStream(ResourceEndpoint.java:77)[91:org.apache.camel.camel-core:2.9.2] at org.apache.camel.component.stringtemplate.StringTemplateEndpoint.onExchange(StringTemplateEndpoint.java:59)[165:org.apache.camel.camel-stringtemplate:2.9.2] The same problem exists by the XSLT component. Kind regards, Tobias |
|
Hi,
Can you submit a small test case into a JIRA[1]? I will have a look at this this week. [1]https://issues.apache.org/jira/browse/CAMEL On Wed Apr 25 17:25:04 2012, Tobias Hofer wrote: > Hi all, > > I switched from Apache Camel version 2.8.4 (in ServiceMix 4.4.1) to the > most recent version 2.9.2. Resource loading in 2.8.4 worked well, but not > in the new release of camel. > > I've a blueprint XML that contains the camel route deployed in the deploy > folder as well as several osgi bundles that contain template resources for > XSLT and String-Template. > > I get the following error: > > java.io.FileNotFoundException: Cannot find resource in classpath for URI: com/example/test.xml > at org.apache.camel.util.ResourceHelper.resolveMandatoryResourceAsInputStream(ResourceHelper.java:89)[91:org.apache.camel.camel-core:2.9.2] > at org.apache.camel.component.ResourceEndpoint.loadResource(ResourceEndpoint.java:92)[91:org.apache.camel.camel-core:2.9.2] > at org.apache.camel.component.ResourceEndpoint.getResourceAsInputStreamWithoutCache(ResourceEndpoint.java:81)[91:org.apache.camel.camel-core:2.9.2] > at org.apache.camel.component.ResourceEndpoint.getResourceAsInputStream(ResourceEndpoint.java:77)[91:org.apache.camel.camel-core:2.9.2] > at org.apache.camel.component.stringtemplate.StringTemplateEndpoint.onExchange(StringTemplateEndpoint.java:59)[165:org.apache.camel.camel-stringtemplate:2.9.2] > > The same problem exists by the XSLT component. > > Kind regards, > Tobias > -- Willem ---------------------------------- CamelOne 2012 Conference, May 15-16, 2012: http://camelone.com FuseSource Web: http://www.fusesource.com Blog: http://willemjiang.blogspot.com (English) http://jnn.javaeye.com (Chinese) Twitter: willemjiang Weibo: willemjiang |
|
In reply to this post by Tobias Hofer
On Wed, Apr 25, 2012 at 11:25 AM, Tobias Hofer <[hidden email]> wrote:
> Hi all, > > I switched from Apache Camel version 2.8.4 (in ServiceMix 4.4.1) to the > most recent version 2.9.2. Resource loading in 2.8.4 worked well, but not > in the new release of camel. > > I've a blueprint XML that contains the camel route deployed in the deploy > folder as well as several osgi bundles that contain template resources for > XSLT and String-Template. > > I get the following error: > > java.io.FileNotFoundException: Cannot find resource in classpath for URI: com/example/test.xml > at org.apache.camel.util.ResourceHelper.resolveMandatoryResourceAsInputStream(ResourceHelper.java:89)[91:org.apache.camel.camel-core:2.9.2] > at org.apache.camel.component.ResourceEndpoint.loadResource(ResourceEndpoint.java:92)[91:org.apache.camel.camel-core:2.9.2] > at org.apache.camel.component.ResourceEndpoint.getResourceAsInputStreamWithoutCache(ResourceEndpoint.java:81)[91:org.apache.camel.camel-core:2.9.2] > at org.apache.camel.component.ResourceEndpoint.getResourceAsInputStream(ResourceEndpoint.java:77)[91:org.apache.camel.camel-core:2.9.2] > at org.apache.camel.component.stringtemplate.StringTemplateEndpoint.onExchange(StringTemplateEndpoint.java:59)[165:org.apache.camel.camel-stringtemplate:2.9.2] > > The same problem exists by the XSLT component. > There was a recent fix on this. Can you try 2.9.3 SNAPSHOT. Also do you use xslt include or something? eg how is your xslt endpoint configured,etc. And do you use Windows or other OS. > Kind regards, > Tobias -- Claus Ibsen ----------------- CamelOne 2012 Conference, May 15-16, 2012: http://camelone.com FuseSource Email: [hidden email] Web: http://fusesource.com Twitter: davsclaus, fusenews Blog: http://davsclaus.blogspot.com/ Author of Camel in Action: http://www.manning.com/ibsen/ |
|
In reply to this post by Willem.Jiang
Hi,
I've created the JIRA Issue CAMEL-5223 and attached a small test case. Regards, Tobias -- Tobias Hofer CTO, Geschäftsleitung basis06 AG - Birkenweg 61 - CH-3013 Bern http://www.basis06.ch - source of smart business ----- Original Message ----- > From: "Willem Jiang" <[hidden email]> > To: [hidden email] > Sent: Wednesday, April 25, 2012 2:59:09 PM > Subject: Re: Cannot find resource in classpath using OSGi blueprint > > Hi, > > Can you submit a small test case into a JIRA[1]? > I will have a look at this this week. > > [1]https://issues.apache.org/jira/browse/CAMEL > > > On Wed Apr 25 17:25:04 2012, Tobias Hofer wrote: > > Hi all, > > > > I switched from Apache Camel version 2.8.4 (in ServiceMix 4.4.1) to > > the > > most recent version 2.9.2. Resource loading in 2.8.4 worked well, > > but not > > in the new release of camel. > > > > I've a blueprint XML that contains the camel route deployed in the > > deploy > > folder as well as several osgi bundles that contain template > > resources for > > XSLT and String-Template. > > > > I get the following error: > > > > java.io.FileNotFoundException: Cannot find resource in classpath > > for URI: com/example/test.xml > > at > > org.apache.camel.util.ResourceHelper.resolveMandatoryResourceAsInputStream(ResourceHelper.java:89)[91:org.apache.camel.camel-core:2.9.2] > > at > > org.apache.camel.component.ResourceEndpoint.loadResource(ResourceEndpoint.java:92)[91:org.apache.camel.camel-core:2.9.2] > > at > > org.apache.camel.component.ResourceEndpoint.getResourceAsInputStreamWithoutCache(ResourceEndpoint.java:81)[91:org.apache.camel.camel-core:2.9.2] > > at > > org.apache.camel.component.ResourceEndpoint.getResourceAsInputStream(ResourceEndpoint.java:77)[91:org.apache.camel.camel-core:2.9.2] > > at > > org.apache.camel.component.stringtemplate.StringTemplateEndpoint.onExchange(StringTemplateEndpoint.java:59)[165:org.apache.camel.camel-stringtemplate:2.9.2] > > > > The same problem exists by the XSLT component. > > > > Kind regards, > > Tobias > > > > > > -- > Willem > ---------------------------------- > CamelOne 2012 Conference, May 15-16, 2012: http://camelone.com > FuseSource > Web: http://www.fusesource.com > Blog: http://willemjiang.blogspot.com (English) > http://jnn.javaeye.com (Chinese) > Twitter: willemjiang > Weibo: willemjiang > > |
|
In reply to this post by Claus Ibsen-2
Hi,
> There was a recent fix on this. Can you try 2.9.3 SNAPSHOT. I tried that version, but the problem still exists here too. > Also do you use xslt include or something? eg how is your xslt > endpoint configured,etc. > And do you use Windows or other OS. No include is used. See CAMEL-5223 for details. Regards, Tobias -- Tobias Hofer CTO, Geschäftsleitung basis06 AG - Birkenweg 61 - CH-3013 Bern http://www.basis06.ch - source of smart business |
| Powered by Nabble | Edit this page |
