> No, this interface isn't in jvm jar file, it's in > org.apache.geronimo.specs.geronimo-jaxws_2.2_spec.jar
Ok, we have no geronimo jar file in the class path. Could you give an example of a full class name of one of the interfaces? Because when I looked at the classes and interfaces for geronimo-jaxws_2.1_spec-1.0.jar (http://www.jarfinder.com/index.php/jars/jarClasses/8262) I found a bunch of interfaces, but they seem to be included in rt.jar in the jvm. For example javax.xml.ws.WebEndpoint. > Can someone explain to me *why* > > Sun's > > jaxws RI breaks the generated webservice client? It just doesn't > > make any > > sense to me... > > Basically this is how java SPI discovery mechanism works, for jaxws > spec, each implementation jar will have a META-INF/services/ > javax.xml.ws.spi.Provider file to specify a impl class. > If classloader load cxf-rt-frontend-jaxws.jar first, it will use > ProviderImpl from cxf, which then can create cxf client and cxf > server, if classloader load Sun's RI first, it will use the one from > Sun's RI. > > Here is a link[1] about what' java SPI, you may need take a look. > [1]http://en.wikipedia.org/wiki/Service_provider_interface Thanks. I looked at the javadoc (http://download.oracle.com/javase/6/docs/api/javax/xml/ws/spi/Provider.html), and as far as I can tell we use the default implementation. Because getClass().getResource("/META-INF/services/javax.xml.ws.spi.Provider") returns null, and so does System.getProperty("javax.xml.ws.spi.Provider"). And we have no file $java.home/lib/jaxws.properties. When I run javax.xml.ws.spi.Provider.provider() I get an instance of com.sun.xml.internal.ws.spi.ProviderImpl which seems to be the default implementation. And using this implementation, our web service client works perfectly. I just wish there was an easy way to make it work even if the Sun RI was in the class path. /Jimi -- View this message in context: http://cxf.547215.n5.nabble.com/Generated-client-gets-error-WSBindingProvider-is-not-visible-from-class-loader-when-jaxws-rt-jar-is-t-tp4269669p4271363.html Sent from the cxf-user mailing list archive at Nabble.com.
