[groovy-user] Is GroovyWS threadsafe - Exceptions with multiple requests

6 views
Skip to first unread message

Bilal Sheikh

unread,
Aug 26, 2008, 10:44:43 AM8/26/08
to us...@groovy.codehaus.org
Hi,

I'm using GroovyWS to integrate a third party WSDL into my Grails project, and my Grails project has to be able to service multiple requests at the same time.  So this is what I have:

- User facing gui sends a HTTP request to a Grails Controller
- Controller calls a Grails Service
- Grails Service creates a new WSClient using the 3rd party WSDL for the request, then makes calls to the 3rd party webservice, then returns the results to the user facing gui as XML

If I do one  request at a time, everything works fine.  However, if I do multiple requests at the same time, it looks like my code breaks when creating a new WSClient.

Is this because I'm creating multiple WSClients (one for each request) at the same time?  Below are the details of the error I get.

Thanks,
Bilal

[21472] errors.GrailsExceptionResolver java.util.ServiceConfigurationError: com.sun.tools.xjc.Plugin: Provider org.apache.cxf.xjc.dv.DefaultValuePlugin not found
org.codehaus.groovy.runtime.InvokerInvocationException: java.util.ServiceConfigurationError: com.sun.tools.xjc.Plugin: Provider org.apache.cxf.xjc.dv.DefaultValuePlugin not found
        at org.jsecurity.web.servlet.FilterChainWrapper.doFilter(FilterChainWrapper.java:49)
        at org.jsecurity.web.servlet.WebInterceptorFilter.doFilter(WebInterceptorFilter.java:66)
        at org.jsecurity.web.servlet.FilterChainWrapper.doFilter(FilterChainWrapper.java:54)
        at org.jsecurity.web.servlet.WebInterceptorFilter.doFilter(WebInterceptorFilter.java:66)
        at org.jsecurity.web.servlet.FilterChainWrapper.doFilter(FilterChainWrapper.java:54)
        at org.jsecurity.web.servlet.WebInterceptorFilter.doFilter(WebInterceptorFilter.java:66)
        at org.jsecurity.web.servlet.FilterChainWrapper.doFilter(FilterChainWrapper.java:54)
        at org.jsecurity.web.servlet.WebInterceptorFilter.doFilter(WebInterceptorFilter.java:66)
        at org.jsecurity.web.servlet.FilterChainWrapper.doFilter(FilterChainWrapper.java:54)
        at org.jsecurity.web.servlet.JSecurityFilter.doFilterInternal(JSecurityFilter.java:519)
        at org.jsecurity.web.servlet.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:111)
Caused by: java.util.ServiceConfigurationError: com.sun.tools.xjc.Plugin: Provider org.apache.cxf.xjc.dv.DefaultValuePlugin not found
        at java.util.ServiceLoader.fail(ServiceLoader.java:214)
        at java.util.ServiceLoader.access$400(ServiceLoader.java:164)
        at java.util.ServiceLoader$LazyIterator.next(ServiceLoader.java:350)
        at java.util.ServiceLoader$1.next(ServiceLoader.java:421)
        at com.sun.tools.xjc.Options.findServices(Options.java:884)
        at com.sun.tools.xjc.Options.getAllPlugins(Options.java:336)
        at com.sun.tools.xjc.reader.AbstractExtensionBindingChecker.<init>(AbstractExtensionBindingChecker.java:94)
        at com.sun.tools.xjc.reader.ExtensionBindingChecker.<init>(ExtensionBindingChecker.java:77)
        at com.sun.tools.xjc.ModelLoader$XMLSchemaParser.parse(ModelLoader.java:257)
        at com.sun.xml.xsom.impl.parser.NGCCRuntimeEx.parseEntity(NGCCRuntimeEx.java:301)
        at com.sun.xml.xsom.impl.parser.ParserContext.parse(ParserContext.java:88)
        at com.sun.xml.xsom.impl.parser.ParserContext.<init>(ParserContext.java:60)
        at com.sun.xml.xsom.parser.XSOMParser.<init>(XSOMParser.java:89)
        at com.sun.tools.xjc.ModelLoader.createXSOMParser(ModelLoader.java:420)
        at com.sun.tools.xjc.ModelLoader.createXSOMParser(ModelLoader.java:428)
        at com.sun.tools.xjc.ModelLoader.createXSOM(ModelLoader.java:509)
        at com.sun.tools.xjc.api.impl.s2j.SchemaCompilerImpl.bind(SchemaCompilerImpl.java:232)
        at com.sun.tools.xjc.api.impl.s2j.SchemaCompilerImpl.bind(SchemaCompilerImpl.java:85)
        at org.apache.cxf.endpoint.dynamic.DynamicClientFactory.createClient(DynamicClientFactory.java:172)
        at org.apache.cxf.endpoint.dynamic.DynamicClientFactory.createClient(DynamicClientFactory.java:143)
        at groovyx.net.ws.WSClient.<init>(WSClient.java:199)
        ... my code which creates a new WSClient object

billy3

unread,
Aug 26, 2008, 10:58:30 AM8/26/08
to us...@groovy.codehaus.org

Hi,

Thanks,
Bilal

--
View this message in context: http://www.nabble.com/Is-GroovyWS-threadsafe---Exceptions-with-multiple-requests-tp19163730p19163730.html
Sent from the groovy - user mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe from this list, please visit:

http://xircles.codehaus.org/manage_email


Reply all
Reply to author
Forward
0 new messages