On 26/11/09 10:14 PM, Karl Pauls wrote:

> Hm, on second thought we still have an issue when several versions of
> felix are running inside the same jvm. I believe that with felix 2.0.2
> or 1.2 we should do the right thing for the bundle: protocol (which is
> what you need iirc) but we probably wont be able to find
> URLStreamHandlerServices from the framework that was registered last.
> I'm working on a patch which should fix this issue at least if the
> next version of felix is started first.

I am actually running into problems regarding what you mentioned while 
instantiating URL objects when Felix 1.2 starts first:

java.lang.ClassNotFoundException: 
org.apache.felix.framework.URLHandlersServiceTracker
        at 
org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1360)
        at 
org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1206)
        at 
org.apache.felix.framework.URLHandlersStreamHandlerProxy.getStreamHandlerService(URLHandlersStreamHandlerProxy.java:232)
        at 
org.apache.felix.framework.URLHandlersStreamHandlerProxy.parseURL(URLHandlersStreamHandlerProxy.java:148)
        at java.net.URL.<init>(URL.java:596)
        at java.net.URL.<init>(URL.java:464)
        at java.net.URL.<init>(URL.java:413)

URLHandlersServiceTracker is a Felix 1.2 class but it's using the Felix 2.0 
frameworks class loader to load the class, which fails because the class is no 
longer in Felix 2.0. Is that one of the problems you were talking about? Do you 
have an idea on how we would patch Felix 1.2 to resolve the issue?
I wasn't able to test what happens if the Felix 2.0 framework starts first, but 
from the looks of it it would fail as well because Felix doesn't have the 
"getStreamHandlerService" method in the 1.2 framework.

Cheers,
Chris

Reply via email to