users@glassfish.java.net

Running Ws client from glassfish throws exception

From: <glassfish_at_javadesktop.org>
Date: Wed, 29 Sep 2010 10:26:44 PDT

Glassfish v3.0.1. Windows. Netbeans 6.8

Create a simple web service in Netbeans. Deployed to Glassfish. Built a web service client based on wsdl in Netbeans 6.8. There is no problem with the client running outside of glassfish. When it is called from an ejb or servlet loaded in the glassfish, the following exception occurred:

SEVERE: java.util.ServiceConfigurationError: javax.xml.ws.spi.Provider:
Provider com.sun.xml.ws.spi.ProviderImpl could not be instantiated:
java.lang.ClassCastException
        at java.util.ServiceLoader.fail(ServiceLoader.java:207)
        at java.util.ServiceLoader.access$100(ServiceLoader.java:164)
        at java.util.ServiceLoader$LazyIterator.next(ServiceLoader.java:353)
        at java.util.ServiceLoader$1.next(ServiceLoader.java:421)
        at javax.xml.ws.spi.Provider.getProviderUsingServiceLoader
(Provider.java:146)
        at javax.xml.ws.spi.Provider.provider(Provider.java:106)
        at javax.xml.ws.Service.<init>(Service.java:57)
        at com.airliquide.soapws.client.dsslookup.DssLookupService.<init>
(DssLookupService.java:58)
....

There are a few issues posted over the time which are quite similar. But I am still not sure how to get around this. Please help.

THanks.
[Message sent by forum member 'hyijun37013']

http://forums.java.net/jive/thread.jspa?messageID=483947