On 6/25/2010 17:11, Serg wrote: > Hi all! > I have a problem with executing PEAR file under cpeGui and others. > My scenario: > 1) UIMA 2.2 or 2.3 > 2) IBM Java 6 (doesn't support JAX-WS v.2.1) > 3) JAX-WS v.2.1 libraries inside PEAR /lib dir. > 4) PEAR file that call web service via JAX-WS libraries - service.jar in > PEAR/lib dir > 5) install.xml - CLASSPATH = list of all jars in /lib(or just /bin -doesn't > matter - the same error) > > During the execution from cpeGUI (or via > org.apache.uima.examples.cpe.SimpleRunCPM) > > got the exception - javax.xml.ws.WebServiceException: Provider > com.sun.xml.ws.spi.ProviderImpl not found > > MANIFEST.MF of the service.jar contains > Class-Path: jaxws-rt.jar ..... - all jars of JAX-WS library > > There is a solution: move all jars from the pear lib directory into UIMA/ > classpath. But it brokes PEAR self-contained conception. > > Another solution - use Sun Java 1.6(so we don't need to keep JAX-WS jars in > PEAR/lib - works fine) - but I need IBM Java. > > How to force UIMA to search and load JAX-WS jars from PEAR/lib? >
Java is trying to load the WS provider from the boot classloader or the extension classloader. The PEAR classpath is provided via a subordinate URL classloader. These two worlds will not come together, there's really no way to do what you're trying to do (I think). Have you tried putting WS jars into the JVM's jre/lib/ext directory? I'm not sure this will work, but it's worth a try. --Thilo
