2009/11/11 lukewpatterson <[email protected]>

>
> In my activator, I'm bundletracking looking for /META-INF/services folders.
> I wrap around the service-providing bundles with a custom ClassLoader and
> then register them with my API's service factory.
>
> This approach seems to work fine except when the /META-INF/services are
> provided exclusively from the Bundle-ClassPath entries.  i.e. doesn't work
> when no /META-INF/services folder on root, but embedded jars on the
> Bundle-ClassPath have the folder
>
> Is Bundle.findEntries(...) [1] supposed to look on the Bundle-Classpath?
>

as the Bundle.findEntries() javadoc states:

   "This bundle's class loader is not used to search for entries"

so it won't look inside embedded jars - you'll need to use
Bundle.getResource() / getResources() for that


> Thanks,
>
> Luke
>
>
> [1]
>
> http://www.osgi.org/javadoc/r4v41/org/osgi/framework/Bundle.html#findEntries%28java.lang.String,%20java.lang.String,%20boolean%29
> --
> View this message in context:
> http://old.nabble.com/Bundle.findEntries%28...%29-and-Bundle-Classpath-tp26287340p26287340.html
> Sent from the Apache Felix - Users mailing list archive at Nabble.com.
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [email protected]
> For additional commands, e-mail: [email protected]
>

-- 
Cheers, Stuart

Reply via email to