Hi all, Following the tread on the dynamic client, I was reading a post by Glen (http://www.jroller.com/gmazza/date/20070929), when I decided to give the NFL strike iron webservice a try with GroovyWS. The fact is that both the web service and cxf are working ... so I must be doing something wrong :-) Here is the cryptic exception I got -- hope it will make sense to one of you !
Doing something similar for the Microsoft Terra webservice just works fine. Any help appreciated Thanks Tog PS: for those interested here is my code: import groovyx.net.ws.WSClient; def proxy = new WSClient("http://sdpwsparam.strikeiron.com/sdpNFLTeams?WSDL", this.class.classLoader) def gtibc = proxy.create("com.strikeiron.GetTeamInfoByCity") println gtibc.class.declaredFields gtibc.userID = "[EMAIL PROTECTED]" gtibc.password = "mysecret" gtibc.city = "New York" def result = proxy.GetTeamInfoByCity(gtibc) Dec 1, 2007 3:21:11 PM org.apache.cxf.phase.PhaseInterceptorChain doIntercept INFO: Interceptor has thrown exception, unwinding now org.apache.cxf.interceptor.Fault: Marshalling Error: Instance of "com.strikeiron.GetTeamInfoByCity" is substituting "java.lang.String", but "com.strikeiron.GetTeamInfoByCity" is bound to an anonymous type. at org.apache.cxf.jaxb.JAXBEncoderDecoder.marshall(JAXBEncoderDecoder.java:187) at org.apache.cxf.jaxb.io.DataWriterImpl.write(DataWriterImpl.java:51) at org.apache.cxf.interceptor.AbstractOutDatabindingInterceptor.writeParts(AbstractOutDatabindingInterceptor.java:84) at org.apache.cxf.interceptor.BareOutInterceptor.handleMessage(BareOutInterceptor.java:68) at org.apache.cxf.phase.PhaseInterceptorChain.doIntercept(PhaseInterceptorChain.java:207) at org.apache.cxf.endpoint.ClientImpl.invoke(ClientImpl.java:254) at org.apache.cxf.endpoint.ClientImpl.invoke(ClientImpl.java:205) at org.apache.cxf.endpoint.ClientImpl.invoke(ClientImpl.java:180) at org.apache.cxf.endpoint.ClientImpl.invoke(ClientImpl.java:200) at org.apache.cxf.endpoint.ClientImpl.invoke(ClientImpl.java:186) at groovyx.net.ws.WSClient.invokeMethod(WSClient.java:73) at org.codehaus.groovy.runtime.Invoker.invokePogoMethod(Invoker.java:102) at org.codehaus.groovy.runtime.Invoker.invokeMethod(Invoker.java:79) at org.codehaus.groovy.runtime.InvokerHelper.invokeMethod(InvokerHelper.java:74) at org.codehaus.groovy.runtime.ScriptBytecodeAdapter.invokeMethodN(ScriptBytecodeAdapter.java:158) at nfl.run(nfl.groovy:12) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:585) at org.codehaus.groovy.reflection.CachedMethod.invokeByReflection(CachedMethod.java:107) at org.codehaus.groovy.reflection.CachedMethod.invoke(CachedMethod.java:127) at org.codehaus.groovy.runtime.metaclass.StdMetaMethod.invoke(StdMetaMethod.java:18) at org.codehaus.groovy.runtime.MetaClassHelper.doMethodInvoke(MetaClassHelper.java:538) at groovy.lang.MetaClassImpl.invokeMethod(MetaClassImpl.java:749) at groovy.lang.MetaClassImpl.invokeMethod(MetaClassImpl.java:589) at org.codehaus.groovy.runtime.Invoker.invokePogoMethod(Invoker.java:98) at org.codehaus.groovy.runtime.Invoker.invokeMethod(Invoker.java:79) at org.codehaus.groovy.runtime.InvokerHelper.invokeMethod(InvokerHelper.java:74) at org.codehaus.groovy.runtime.InvokerHelper.runScript(InvokerHelper.java:374) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:585) at org.codehaus.groovy.reflection.CachedMethod.invokeByReflection(CachedMethod.java:107) at org.codehaus.groovy.reflection.CachedMethod.invoke(CachedMethod.java:127) at org.codehaus.groovy.runtime.metaclass.StdMetaMethod.invoke(StdMetaMethod.java:18) at org.codehaus.groovy.runtime.MetaClassHelper.doMethodInvoke(MetaClassHelper.java:538) at groovy.lang.MetaClassImpl.invokeStaticMethod(MetaClassImpl.java:873) at org.codehaus.groovy.runtime.Invoker.invokeMethod(Invoker.java:69) at org.codehaus.groovy.runtime.InvokerHelper.invokeMethod(InvokerHelper.java:74) at org.codehaus.groovy.runtime.ScriptBytecodeAdapter.invokeMethodN(ScriptBytecodeAdapter.java:158) at nfl.main(nfl.groovy) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:585) at org.codehaus.groovy.reflection.CachedMethod.invokeByReflection(CachedMethod.java:107) at org.codehaus.groovy.reflection.CachedMethod.invoke(CachedMethod.java:127) at org.codehaus.groovy.runtime.metaclass.StdMetaMethod.invoke(StdMetaMethod.java:18) at org.codehaus.groovy.runtime.MetaClassHelper.doMethodInvoke(MetaClassHelper.java:538) at groovy.lang.MetaClassImpl.invokeStaticMethod(MetaClassImpl.java:873) at org.codehaus.groovy.runtime.Invoker.invokeMethod(Invoker.java:69) at org.codehaus.groovy.runtime.InvokerHelper.invokeMethod(InvokerHelper.java:74) at groovy.lang.GroovyShell.runMainOrTestOrRunnable(GroovyShell.java:244) at groovy.lang.GroovyShell.run(GroovyShell.java:218) at groovy.lang.GroovyShell.run(GroovyShell.java:147) at groovy.ui.GroovyMain.processOnce(GroovyMain.java:492) at groovy.ui.GroovyMain.run(GroovyMain.java:308) at groovy.ui.GroovyMain.process(GroovyMain.java:294) at groovy.ui.GroovyMain.processArgs(GroovyMain.java:111) at groovy.ui.GroovyMain.main(GroovyMain.java:92) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:585) at org.codehaus.groovy.tools.GroovyStarter.rootLoader(GroovyStarter.java:101) at org.codehaus.groovy.tools.GroovyStarter.main(GroovyStarter.java:130) Caused by: javax.xml.bind.MarshalException - with linked exception: [com.sun.istack.SAXException2: Instance of "com.strikeiron.GetTeamInfoByCity" is substituting "java.lang.String", but "com.strikeiron.GetTeamInfoByCity" is bound to an anonymous type.] at com.sun.xml.bind.v2.runtime.MarshallerImpl.write(MarshallerImpl.java:304) at com.sun.xml.bind.v2.runtime.MarshallerImpl.marshal(MarshallerImpl.java:230) at javax.xml.bind.helpers.AbstractMarshallerImpl.marshal(AbstractMarshallerImpl.java:75) at org.apache.cxf.jaxb.JAXBEncoderDecoder.writeObject(JAXBEncoderDecoder.java:330) at org.apache.cxf.jaxb.JAXBEncoderDecoder.marshall(JAXBEncoderDecoder.java:167) ... 67 more Caused by: com.sun.istack.SAXException2: Instance of "com.strikeiron.GetTeamInfoByCity" is substituting "java.lang.String", but "com.strikeiron.GetTeamInfoByCity" is bound to an anonymous type. at com.sun.xml.bind.v2.runtime.XMLSerializer.reportError(XMLSerializer.java:226) at com.sun.xml.bind.v2.runtime.XMLSerializer.childAsXsiType(XMLSerializer.java:641) at com.sun.xml.bind.v2.runtime.ElementBeanInfoImpl$1.serializeBody(ElementBeanInfoImpl.java:115) at com.sun.xml.bind.v2.runtime.ElementBeanInfoImpl$1.serializeBody(ElementBeanInfoImpl.java:149) at com.sun.xml.bind.v2.runtime.ElementBeanInfoImpl.serializeBody(ElementBeanInfoImpl.java:269) at com.sun.xml.bind.v2.runtime.ElementBeanInfoImpl.serializeRoot(ElementBeanInfoImpl.java:276) at com.sun.xml.bind.v2.runtime.ElementBeanInfoImpl.serializeRoot(ElementBeanInfoImpl.java:35) at com.sun.xml.bind.v2.runtime.XMLSerializer.childAsRoot(XMLSerializer.java:472) at com.sun.xml.bind.v2.runtime.MarshallerImpl.write(MarshallerImpl.java:301) ... 71 more org.apache.cxf.interceptor.Fault: Marshalling Error: Instance of "com.strikeiron.GetTeamInfoByCity" is substituting "java.lang.String", but "com.strikeiron.GetTeamInfoByCity" is bound to an anonymous type. at org.apache.cxf.jaxb.JAXBEncoderDecoder.marshall(JAXBEncoderDecoder.java:187) at org.apache.cxf.jaxb.io.DataWriterImpl.write(DataWriterImpl.java:51) at org.apache.cxf.interceptor.AbstractOutDatabindingInterceptor.writeParts(AbstractOutDatabindingInterceptor.java:84) at org.apache.cxf.interceptor.BareOutInterceptor.handleMessage(BareOutInterceptor.java:68) at org.apache.cxf.phase.PhaseInterceptorChain.doIntercept(PhaseInterceptorChain.java:207) at org.apache.cxf.endpoint.ClientImpl.invoke(ClientImpl.java:254) at org.apache.cxf.endpoint.ClientImpl.invoke(ClientImpl.java:205) at org.apache.cxf.endpoint.ClientImpl.invoke(ClientImpl.java:180) at org.apache.cxf.endpoint.ClientImpl.invoke(ClientImpl.java:200) at org.apache.cxf.endpoint.ClientImpl.invoke(ClientImpl.java:186) at groovyx.net.ws.WSClient.invokeMethod(WSClient.java:73) at org.codehaus.groovy.runtime.Invoker.invokePogoMethod(Invoker.java:102) at org.codehaus.groovy.runtime.Invoker.invokeMethod(Invoker.java:79) at org.codehaus.groovy.runtime.InvokerHelper.invokeMethod(InvokerHelper.java:74) at org.codehaus.groovy.runtime.ScriptBytecodeAdapter.invokeMethodN(ScriptBytecodeAdapter.java:158) at nfl.run(nfl.groovy:12) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:585) at org.codehaus.groovy.reflection.CachedMethod.invokeByReflection(CachedMethod.java:107) at org.codehaus.groovy.reflection.CachedMethod.invoke(CachedMethod.java:127) at org.codehaus.groovy.runtime.metaclass.StdMetaMethod.invoke(StdMetaMethod.java:18) at org.codehaus.groovy.runtime.MetaClassHelper.doMethodInvoke(MetaClassHelper.java:538) at groovy.lang.MetaClassImpl.invokeMethod(MetaClassImpl.java:749) at groovy.lang.MetaClassImpl.invokeMethod(MetaClassImpl.java:589) at org.codehaus.groovy.runtime.Invoker.invokePogoMethod(Invoker.java:98) at org.codehaus.groovy.runtime.Invoker.invokeMethod(Invoker.java:79) at org.codehaus.groovy.runtime.InvokerHelper.invokeMethod(InvokerHelper.java:74) at org.codehaus.groovy.runtime.InvokerHelper.runScript(InvokerHelper.java:374) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:585) at org.codehaus.groovy.reflection.CachedMethod.invokeByReflection(CachedMethod.java:107) at org.codehaus.groovy.reflection.CachedMethod.invoke(CachedMethod.java:127) at org.codehaus.groovy.runtime.metaclass.StdMetaMethod.invoke(StdMetaMethod.java:18) at org.codehaus.groovy.runtime.MetaClassHelper.doMethodInvoke(MetaClassHelper.java:538) at groovy.lang.MetaClassImpl.invokeStaticMethod(MetaClassImpl.java:873) at org.codehaus.groovy.runtime.Invoker.invokeMethod(Invoker.java:69) at org.codehaus.groovy.runtime.InvokerHelper.invokeMethod(InvokerHelper.java:74) at org.codehaus.groovy.runtime.ScriptBytecodeAdapter.invokeMethodN(ScriptBytecodeAdapter.java:158) at nfl.main(nfl.groovy) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:585) at org.codehaus.groovy.reflection.CachedMethod.invokeByReflection(CachedMethod.java:107) at org.codehaus.groovy.reflection.CachedMethod.invoke(CachedMethod.java:127) at org.codehaus.groovy.runtime.metaclass.StdMetaMethod.invoke(StdMetaMethod.java:18) at org.codehaus.groovy.runtime.MetaClassHelper.doMethodInvoke(MetaClassHelper.java:538) at groovy.lang.MetaClassImpl.invokeStaticMethod(MetaClassImpl.java:873) at org.codehaus.groovy.runtime.Invoker.invokeMethod(Invoker.java:69) at org.codehaus.groovy.runtime.InvokerHelper.invokeMethod(InvokerHelper.java:74) at groovy.lang.GroovyShell.runMainOrTestOrRunnable(GroovyShell.java:244) at groovy.lang.GroovyShell.run(GroovyShell.java:218) at groovy.lang.GroovyShell.run(GroovyShell.java:147) at groovy.ui.GroovyMain.processOnce(GroovyMain.java:492) at groovy.ui.GroovyMain.run(GroovyMain.java:308) at groovy.ui.GroovyMain.process(GroovyMain.java:294) at groovy.ui.GroovyMain.processArgs(GroovyMain.java:111) at groovy.ui.GroovyMain.main(GroovyMain.java:92) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:585) at org.codehaus.groovy.tools.GroovyStarter.rootLoader(GroovyStarter.java:101) at org.codehaus.groovy.tools.GroovyStarter.main(GroovyStarter.java:130) Caused by: javax.xml.bind.MarshalException - with linked exception: [com.sun.istack.SAXException2: Instance of "com.strikeiron.GetTeamInfoByCity" is substituting "java.lang.String", but "com.strikeiron.GetTeamInfoByCity" is bound to an anonymous type.] at com.sun.xml.bind.v2.runtime.MarshallerImpl.write(MarshallerImpl.java:304) at com.sun.xml.bind.v2.runtime.MarshallerImpl.marshal(MarshallerImpl.java:230) at javax.xml.bind.helpers.AbstractMarshallerImpl.marshal(AbstractMarshallerImpl.java:75) at org.apache.cxf.jaxb.JAXBEncoderDecoder.writeObject(JAXBEncoderDecoder.java:330) at org.apache.cxf.jaxb.JAXBEncoderDecoder.marshall(JAXBEncoderDecoder.java:167) ... 67 more Caused by: com.sun.istack.SAXException2: Instance of "com.strikeiron.GetTeamInfoByCity" is substituting "java.lang.String", but "com.strikeiron.GetTeamInfoByCity" is bound to an anonymous type. at com.sun.xml.bind.v2.runtime.XMLSerializer.reportError(XMLSerializer.java:226) at com.sun.xml.bind.v2.runtime.XMLSerializer.childAsXsiType(XMLSerializer.java:641) at com.sun.xml.bind.v2.runtime.ElementBeanInfoImpl$1.serializeBody(ElementBeanInfoImpl.java:115) at com.sun.xml.bind.v2.runtime.ElementBeanInfoImpl$1.serializeBody(ElementBeanInfoImpl.java:149) at com.sun.xml.bind.v2.runtime.ElementBeanInfoImpl.serializeBody(ElementBeanInfoImpl.java:269) at com.sun.xml.bind.v2.runtime.ElementBeanInfoImpl.serializeRoot(ElementBeanInfoImpl.java:276) at com.sun.xml.bind.v2.runtime.ElementBeanInfoImpl.serializeRoot(ElementBeanInfoImpl.java:35) at com.sun.xml.bind.v2.runtime.XMLSerializer.childAsRoot(XMLSerializer.java:472) at com.sun.xml.bind.v2.runtime.MarshallerImpl.write(MarshallerImpl.java:301) ... 71 more -- Best Regards Guillaume http://cheztog.blogspot.com