Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8622929
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 12, 20262026-06-12T07:09:58+00:00 2026-06-12T07:09:58+00:00

I have an OSGi bundle (deployed into Karaf 2.2.4) that starts a Camel (2.10.0)

  • 0

I have an OSGi bundle (deployed into Karaf 2.2.4) that starts a Camel (2.10.0) context. The Camel context’s routebuilder has some xquery endpoint URIs such as

"xquery:classpath:Dir1/Dir2/example.xq"

When the context tried to resolve that URI, it failed since the Camel bundle is not in the same classpath as where the .xq file resides. So, I created a url expand function that turns

"xquery:classpath:..."

into

"xquery:bundle://42.0:6/..."

since I had dealt with bundle URIs and the OsgiBundleResourcePatternResolver earlier in my project when dealing with a ClassPathScanningCandidateComponentProvider (Spring 3.1.1). Unfortunately, I can’t seem to find a way to make Camel’s XQueryComponent use my OsgiBundleResourcePatternResolver.

  1. Am I going about this the right way? Is there an easier way to do this?
  2. If I am, how can I make sure the XQueryComponent can understand a bundle: URI?
  3. Also, is it possible for me to make sure any camel component can understand a bundle: URI?
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-12T07:10:00+00:00Added an answer on June 12, 2026 at 7:10 am

    Thanks to Claus’ answer, I was able to realize that my .xq file was not in the right directory in its .jar.

    Dir1 resided in root of its .jar file. While running the application in a non-OSGi web container worked fine, Karaf appears to be more strict regarding where resources should be in my .war file. I moved the .xq files to WEB-INF/classes/Dir1/... and now am no longer receiving FileNotFoundExceptions when the code uses xquery:classpath:Dir1/Dir2/example.xq

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have an OSGi bundle which is deployed into Apache Karaf 2.2.8 . In
I have an OSGi bundle deployed on Apache Karaf . I have a simple
I have a 3rd party JAR that I have converted to an OSGI bundle
I have a server application that consists of multiple OSGi bundles, some mine, some
I have two OSGi bundles deployed in Apache Karaf . A and B .
I have a simple CXF RS bundle deployed in Fuse 4.2 that works fine
I have two OSGi bundles deployed on Apache Karaf container. Lets say they are
I have an OSGi bundle that can also run in plain Java process. I
Which maven plugin is used for building an osgi bundle containing camel-routes and some
I have a project that I am trying to convert to OSGi. However, this

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.