webservice call gave ClientTransportException

0
I published (started) a very basic webservice from Apache-Tomcat application-server on localhost:8080. Configured the Imported WebService and WebService call in Mendix. After deploying (runtime port 8081, admin port 8090) I received an error "An error has occurred while handling the request". However, the server sent HTTP status code 200 gave status OK. Can anybody help me figuring out what's going on? Stack trace: Advanced stacktrace: at mq.a(SourceFile:187) Caused by: com.sun.xml.ws.client.ClientTransportException: The server sent HTTP status code 200: OK at com.sun.xml.ws.transport.http.client.HttpTransportPipe.createResponsePacket(HttpTransportPipe.java:314) at com.sun.xml.ws.transport.http.client.HttpTransportPipe.process(HttpTransportPipe.java:265) at com.sun.xml.ws.transport.http.client.HttpTransportPipe.processRequest(HttpTransportPipe.java:184) at com.sun.xml.ws.transport.DeferredTransportPipe.processRequest(DeferredTransportPipe.java:137) at com.sun.xml.ws.api.pipe.Fiber.__doRun(Fiber.java:641) at com.sun.xml.ws.api.pipe.Fiber._doRun(Fiber.java:600) at com.sun.xml.ws.api.pipe.Fiber.doRun(Fiber.java:585) at com.sun.xml.ws.api.pipe.Fiber.runSync(Fiber.java:482) at com.sun.xml.ws.client.Stub.process(Stub.java:323) at com.sun.xml.ws.client.dispatch.DispatchImpl.doInvoke(DispatchImpl.java:192) at com.sun.xml.ws.client.dispatch.DispatchImpl.invoke(DispatchImpl.java:218) at nu$2.a(SourceFile:348) at nu$2.run(SourceFile:294) at java.security.AccessController.doPrivileged(Native Method) at nu.a(SourceFile:283) at nu.a(SourceFile:134) at com.mendix.modules.webservices.WebserviceModule.callWebservice(SourceFile:231) at ls.a(SourceFile:79) at mq.a(SourceFile:72) at mp.a(SourceFile:151) at mp.executeAction(SourceFile:98) at com.mendix.systemwideinterfaces.core.UserAction.execute(SourceFile:57) at com.mendix.core.actionmanagement.CoreAction.call(SourceFile:457) at hA.b(SourceFile:193) at com.mendix.core.Core.execute(SourceFile:219) at gl.execute(SourceFile:186) at ja.a(SourceFile:319) at com.mendix.externalinterface.connector.RequestDispatching$Worker.a(SourceFile:157) at com.mendix.externalinterface.connector.RequestDispatching$Worker$a.a(SourceFile:148) at com.mendix.externalinterface.connector.RequestDispatching$Worker$a.apply(SourceFile:147) at akka.actor.Actor$class.apply(Actor.scala:545) at com.mendix.externalinterface.connector.RequestDispatching$Worker.apply(SourceFile:143) at akka.actor.LocalActorRef.invoke(ActorRef.scala:910) at akka.dispatch.MessageInvocation.invoke(MessageHandling.scala:25) at akka.dispatch.ExecutableMailbox$class.processMailbox(ExecutorBasedEventDrivenDispatcher.scala:223) at akka.dispatch.ExecutorBasedEventDrivenDispatcher$$anon$4.processMailbox(ExecutorBasedEventDrivenDispatcher.scala:123) at akka.dispatch.ExecutableMailbox$class.run(ExecutorBasedEventDrivenDispatcher.scala:195) at akka.dispatch.ExecutorBasedEventDrivenDispatcher$$anon$4.run(ExecutorBasedEventDrivenDispatcher.scala:123) at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908) at java.lang.Thread.run(Thread.java:662) at akka.dispatch.MonitorableThread.run(ThreadPoolBuilder.scala:192)' With the webservices log node set to trace I received: Response exception received in Tube [ MesageDumpingTube ] Instance [ 1 ] Engine [ Metro/2.1 (branches/2.1-6728; 2011-02-03T14:14:58+0000) JAXWS-RI/2.2.3 JAXWS/2.2: Stub for http://tempuri.org ] Thread [ akka:event-driven:dispatcher:request-dispatching-17 ]: com.sun.xml.ws.client. ClientTransportException: The server sent HTTP status code 200: OK at com.sun.xml.ws.transport.http.client.HttpTransportPipe.createResponsePacket(HttpTransportPipe.java:314) at com.sun.xml.ws.transport.http.client.HttpTransportPipe.process(HttpTransportPipe.java:265) at com.sun.xml.ws.transport.http.client.HttpTransportPipe.processRequest(HttpTransportPipe.java:184) at com.sun.xml.ws.transport.DeferredTransportPipe.processRequest(DeferredTransportPipe.java:137) at com.sun.xml.ws.api.pipe.Fiber.__doRun(Fiber.java:641) at com.sun.xml.ws.api.pipe.Fiber._doRun(Fiber.java:600) at com.sun.xml.ws.api.pipe.Fiber.doRun(Fiber.java:585) at com.sun.xml.ws.api.pipe.Fiber.runSync(Fiber.java:482) at com.sun.xml.ws.client.Stub.process(Stub.java:323) at com.sun.xml.ws.client.dispatch.DispatchImpl.doInvoke(DispatchImpl.java:192) at com.sun.xml.ws.client.dispatch.DispatchImpl.invoke(DispatchImpl.java:218) at nu$2.a(SourceFile:316) at nu$2.run(SourceFile:294) at java.security.AccessController.doPrivileged(Native Method) at nu.a(SourceFile:283) at nu.a(SourceFile:134) at com.mendix.modules.webservices.WebserviceModule.callWebservice(SourceFile:231) at ls.a(SourceFile:79) at mq.a(SourceFile:72) at mp.a(SourceFile:151) at mp.executeAction(SourceFile:98) at com.mendix.systemwideinterfaces.core.UserAction.execute(SourceFile:57) at com.mendix.core.actionmanagement.CoreAction.call(SourceFile:457) at hA.b(SourceFile:193) at com.mendix.core.Core.execute(SourceFile:219) at gl.execute(SourceFile:186) at ja.a(SourceFile:319) at com.mendix.externalinterface.connector.RequestDispatching$Worker.a(SourceFile:157) at com.mendix.externalinterface.connector.RequestDispatching$Worker$a.a(SourceFile:148) at com.mendix.externalinterface.connector.RequestDispatching$Worker$a.apply(SourceFile:147) at akka.actor.Actor$class.apply(Actor.scala:545) at com.mendix.externalinterface.connector.RequestDispatching$Worker.apply(SourceFile:143) at akka.actor.LocalActorRef.invoke(ActorRef.scala:910) at akka.dispatch.MessageInvocation.invoke(MessageHandling.scala:25) at akka.dispatch.ExecutableMailbox$class.processMailbox(ExecutorBasedEventDrivenDispatcher.scala:223) at akka.dispatch.ExecutorBasedEventDrivenDispatcher$$anon$4.processMailbox(ExecutorBasedEventDrivenDispatcher.scala:123) at akka.dispatch.ExecutableMailbox$class.run(ExecutorBasedEventDrivenDispatcher.scala:195) at akka.dispatch.ExecutorBasedEventDrivenDispatcher$$anon$4.run(ExecutorBasedEventDrivenDispatcher.scala:123) at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908) at java.lang.Thread.run(Thread.java:662) at akka.dispatch.MonitorableThread.run(ThreadPoolBuilder.scala:192) After that I filled in a value for Imported web-service location constant, giving rise to another error. Stack trace: ld: Couldnt create SOAP message due to exception: unexpected XML tag. expected: {http://schemas.xmlsoap.org/soap/envelope/}Envelope but found: {http://schemas.xmlsoap.org/wsdl/}definitions at Ws.NAV_WsConsume (CallWebservice : Call web service CalculateRectArea) Advanced stacktrace: at mq.a(SourceFile:187) Caused by: com.sun.xml.ws.protocol.soap.MessageCreationException: Couldnt create SOAP message due to exception: unexpected XML tag. expected: {http://schemas.xmlsoap.org/soap/envelope/}Envelope but found: {http://schemas.xmlsoap.org/wsdl/}definitions at com.sun.xml.ws.encoding.SOAPBindingCodec.decode(SOAPBindingCodec.java:363) at com.sun.xml.ws.transport.http.client.HttpTransportPipe.createResponsePacket(HttpTransportPipe.java:316) at com.sun.xml.ws.transport.http.client.HttpTransportPipe.process(HttpTransportPipe.java:265) at com.sun.xml.ws.transport.http.client.HttpTransportPipe.processRequest(HttpTransportPipe.java:184) at com.sun.xml.ws.transport.DeferredTransportPipe.processRequest(DeferredTransportPipe.java:137) at com.sun.xml.ws.api.pipe.Fiber.__doRun(Fiber.java:641) at com.sun.xml.ws.api.pipe.Fiber._doRun(Fiber.java:600) at com.sun.xml.ws.api.pipe.Fiber.doRun(Fiber.java:585) at com.sun.xml.ws.api.pipe.Fiber.runSync(Fiber.java:482) at com.sun.xml.ws.client.Stub.process(Stub.java:323) at com.sun.xml.ws.client.dispatch.DispatchImpl.doInvoke(DispatchImpl.java:192) at com.sun.xml.ws.client.dispatch.DispatchImpl.invoke(DispatchImpl.java:218) at nu$2.a(SourceFile:316) at nu$2.run(SourceFile:294) at java.security.AccessController.doPrivileged(Native Method) at nu.a(SourceFile:283) at nu.a(SourceFile:134) at com.mendix.modules.webservices.WebserviceModule.callWebservice(SourceFile:231) at ls.a(SourceFile:79) at mq.a(SourceFile:72) at mp.a(SourceFile:151) at mp.executeAction(SourceFile:98) at com.mendix.systemwideinterfaces.core.UserAction.execute(SourceFile:57) at com.mendix.core.actionmanagement.CoreAction.call(SourceFile:457) at hA.b(SourceFile:193) at com.mendix.core.Core.execute(SourceFile:219) at gl.execute(SourceFile:186) at ja.a(SourceFile:319) at com.mendix.externalinterface.connector.RequestDispatching$Worker.a(SourceFile:157) at com.mendix.externalinterface.connector.RequestDispatching$Worker$a.a(SourceFile:148) at com.mendix.externalinterface.connector.RequestDispatching$Worker$a.apply(SourceFile:147) at akka.actor.Actor$class.apply(Actor.scala:545) at com.mendix.externalinterface.connector.RequestDispatching$Worker.apply(SourceFile:143) at akka.actor.LocalActorRef.invoke(ActorRef.scala:910) at akka.dispatch.MessageInvocation.invoke(MessageHandling.scala:25) at akka.dispatch.ExecutableMailbox$class.processMailbox(ExecutorBasedEventDrivenDispatcher.scala:223) at akka.dispatch.ExecutorBasedEventDrivenDispatcher$$anon$4.processMailbox(ExecutorBasedEventDrivenDispatcher.scala:123) at akka.dispatch.ExecutableMailbox$class.run(ExecutorBasedEventDrivenDispatcher.scala:195) at akka.dispatch.ExecutorBasedEventDrivenDispatcher$$anon$4.run(ExecutorBasedEventDrivenDispatcher.scala:123) at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908) at java.lang.Thread.run(Thread.java:662) at akka.dispatch.MonitorableThread.run(ThreadPoolBuilder.scala:192) Caused by: com.sun.xml.ws.streaming.XMLStreamReaderException: unexpected XML tag. expected: {http://schemas.xmlsoap.org/soap/envelope/}Envelope but found: {http://schemas.xmlsoap.org/wsdl/}definitions at com.sun.xml.ws.streaming.XMLStreamReaderUtil.verifyTag(XMLStreamReaderUtil.java:218) at com.sun.xml.ws.encoding.StreamSOAPCodec.decode(StreamSOAPCodec.java:184) at com.sun.xml.ws.encoding.StreamSOAPCodec.decode(StreamSOAPCodec.java:307) at com.sun.xml.ws.encoding.StreamSOAPCodec.decode(StreamSOAPCodec.java:133) at com.sun.xml.ws.encoding.SOAPBindingCodec.decode(SOAPBindingCodec.java:358) at com.sun.xml.ws.transport.http.client.HttpTransportPipe.createResponsePacket(HttpTransportPipe.java:316) at com.sun.xml.ws.transport.http.client.HttpTransportPipe.process(HttpTransportPipe.java:265) at com.sun.xml.ws.transport.http.client.HttpTransportPipe.processRequest(HttpTransportPipe.java:184) at com.sun.xml.ws.transport.DeferredTransportPipe.processRequest(DeferredTransportPipe.java:137) at com.sun.xml.ws.api.pipe.Fiber.__doRun(Fiber.java:641) at com.sun.xml.ws.api.pipe.Fiber._doRun(Fiber.java:600) at com.sun.xml.ws.api.pipe.Fiber.doRun(Fiber.java:585) at com.sun.xml.ws.api.pipe.Fiber.runSync(Fiber.java:482) at com.sun.xml.ws.client.Stub.process(Stub.java:323) at com.sun.xml.ws.client.dispatch.DispatchImpl.doInvoke(DispatchImpl.java:192) at com.sun.xml.ws.client.dispatch.DispatchImpl.invoke(DispatchImpl.java:218) at nu$2.a(SourceFile:316) at nu$2.run(SourceFile:294) at java.security.AccessController.doPrivileged(Native Method) at nu.a(SourceFile:283) at nu.a(SourceFile:134) at com.mendix.modules.webservices.WebserviceModule.callWebservice(SourceFile:231) at ls.a(SourceFile:79) at mq.a(SourceFile:72) at mp.a(SourceFile:151) at mp.executeAction(SourceFile:98) at com.mendix.systemwideinterfaces.core.UserAction.execute(SourceFile:57) at com.mendix.core.actionmanagement.CoreAction.call(SourceFile:457) at hA.b(SourceFile:193) at com.mendix.core.Core.execute(SourceFile:219) at gl.execute(SourceFile:186) at ja.a(SourceFile:319) at com.mendix.externalinterface.connector.RequestDispatching$Worker.a(SourceFile:157) at com.mendix.externalinterface.connector.RequestDispatching$Worker$a.a(SourceFile:148) at com.mendix.externalinterface.connector.RequestDispatching$Worker$a.apply(SourceFile:147) at akka.actor.Actor$class.apply(Actor.scala:545) at com.mendix.externalinterface.connector.RequestDispatching$Worker.apply(SourceFile:143) at akka.actor.LocalActorRef.invoke(ActorRef.scala:910) at akka.dispatch.MessageInvocation.invoke(MessageHandling.scala:25) at akka.dispatch.ExecutableMailbox$class.processMailbox(ExecutorBasedEventDrivenDispatcher.scala:223) at akka.dispatch.ExecutorBasedEventDrivenDispatcher$$anon$4.processMailbox(ExecutorBasedEventDrivenDispatcher.scala:123) at akka.dispatch.ExecutableMailbox$class.run(ExecutorBasedEventDrivenDispatcher.scala:195) at akka.dispatch.ExecutorBasedEventDrivenDispatcher$$anon$4.run(ExecutorBasedEventDrivenDispatcher.scala:123) at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908) at java.lang.Thread.run(Thread.java:662) at akka.dispatch.MonitorableThread.run(ThreadPoolBuilder.scala:192)
asked
5 answers
2

I have had this issue recently. I realize this is a post from 2013, but my answer is for other people with the same issue, for future reference.

In my case: we used constants for end-points and on one of the environments we had an end-point constant populated with the WS-DOC location, instead of the actual location of the webservice. The HTTP 200 OK is the correct "soap" response, since there is no error on the called website. But there is no webservice there being able to process the request.

So, verify if the constant is populated in a format with /ws/ , for example: http://localhost:8080/ws/WSGetListPerson10/

answered
0

Please turn on debug log for webservice and paste the request and response here . Probably that will help others to understand what error is there for XML parsing or ....

answered
0

Please turn on debug log for webservice and paste the request and response here . Probably that will help others to understand what error is there for XML parsing or else.

answered
0

Probably you can turn on debug mode of logging for webservice and see what XML and parsing you are doing.

answered
0

I have seen something similar before, does the webservice by any chance return the content type text/html instead of text/xml in the http header?

If not, set the webservices and xml import lognode to trace.

answered