• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

weblogic.xml.saaj.VersionMismatchException: unable to locate Envelope in namespace

 
SaravanaKumar Venugopal
Greenhorn
Posts: 23
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
All,
When I am trying to consume a webservice I am getting the below exception, can any of you please help me in ressolving the issue.



Caused by: weblogic.xml.saaj.VersionMismatchException: unable to locate Envelope in namespace http://schemas.xmlsoap.org/soap/envelope/. Root element is "http://schemas.xmlsoap.org/wsdl/" in namespace "definitions"
at weblogic.xml.saaj.SaajDocument.getEnvelope(SaajDocument.java:107)
at weblogic.xml.saaj.SOAPPartImpl.envelope(SOAPPartImpl.java:77)
at weblogic.xml.saaj.SOAPPartImpl.getEnvelope(SOAPPartImpl.java:72)
at weblogic.xml.saaj.SOAPMessageImpl.<init>(SOAPMessageImpl.java:156)
at weblogic.xml.saaj.MessageFactoryImpl.createMessage(MessageFactoryImpl.java:76)
at weblogic.wsee.connection.soap.SoapClientConnection.createSOAPMessage(SoapClientConnection.java:134)
at weblogic.wsee.connection.soap.SoapConnection.receive(SoapConnection.java:515)
... 9 more
Caused by: weblogic.xml.saaj.VersionMismatchException: unable to locate Envelope in namespace http://schemas.xmlsoap.org/soap/envelope/. Root element is "http://schemas.xmlsoap.org/wsdl/" in namespace "definitions"
at weblogic.xml.saaj.SaajDocument.getEnvelope(SaajDocument.java:107)
at weblogic.xml.saaj.SOAPPartImpl.envelope(SOAPPartImpl.java:77)
at weblogic.xml.saaj.SOAPPartImpl.getEnvelope(SOAPPartImpl.java:72)
at weblogic.xml.saaj.SOAPMessageImpl.<init>(SOAPMessageImpl.java:156)
at weblogic.xml.saaj.MessageFactoryImpl.createMessage(MessageFactoryImpl.java:76)
at weblogic.wsee.connection.soap.SoapClientConnection.createSOAPMessage(SoapClientConnection.java:134)
at weblogic.wsee.connection.soap.SoapConnection.receive(SoapConnection.java:515)
at weblogic.wsee.ws.dispatch.client.ConnectionHandler.handleResponse(ConnectionHandler.java:179)
at weblogic.wsee.handler.HandlerIterator.handleResponse(HandlerIterator.java:287)
at weblogic.wsee.handler.HandlerIterator.handleResponse(HandlerIterator.java:271)
at weblogic.wsee.ws.dispatch.client.ClientDispatcher.handleResponse(ClientDispatcher.java:213)
at weblogic.wsee.ws.dispatch.client.ClientDispatcher.dispatch(ClientDispatcher.java:150)
at weblogic.wsee.ws.WsStub.invoke(WsStub.java:87)
at weblogic.wsee.jaxrpc.StubImpl._invoke(StubImpl.java:339)
at com.qwest.rdb.wsdl.ants.LegalEntityCode_V1PortType_Stub.opGet(Unknown Source)
at com.qwest.odb.tester.AntsDemoHandler.main(AntsDemoHandler.java:71)
</bea_fault:stacktrace></detail>]; nested exception is:
weblogic.wsee.jaxrpc.soapfault.WLSOAPFaultException: Failed to receive message java.io.IOException: Could not parse SOAP message. Remaining stream ...
-> Could not parse SOAP message. Remaining stream ...

at com.qwest.rdb.wsdl.ants.LegalEntityCode_V1PortType_Stub.opGet(Unknown Source)
at com.qwest.odb.tester.AntsDemoHandler.main(AntsDemoHandler.java:71)
Caused by: weblogic.wsee.jaxrpc.soapfault.WLSOAPFaultException: Failed to receive message java.io.IOException: Could not parse SOAP message. Remaining stream ...
-> Could not parse SOAP message. Remaining stream ...

at weblogic.wsee.codec.soap11.SoapCodec.decodeFault(SoapCodec.java:357)
at weblogic.wsee.ws.dispatch.client.CodecHandler.decodeFault(CodecHandler.java:118)
at weblogic.wsee.ws.dispatch.client.CodecHandler.decode(CodecHandler.java:103)
at weblogic.wsee.ws.dispatch.client.CodecHandler.handleFault(CodecHandler.java:91)
at weblogic.wsee.handler.HandlerIterator.handleFault(HandlerIterator.java:309)
at weblogic.wsee.handler.HandlerIterator.handleResponse(HandlerIterator.java:269)
at weblogic.wsee.ws.dispatch.client.ClientDispatcher.handleResponse(ClientDispatcher.java:213)
at weblogic.wsee.ws.dispatch.client.ClientDispatcher.dispatch(ClientDispatcher.java:150)
at weblogic.wsee.ws.WsStub.invoke(WsStub.java:87)
at weblogic.wsee.jaxrpc.StubImpl._invoke(StubImpl.java:339)
... 2 more
Caused by: weblogic.wsee.handler.InvocationException: Failed to receive message java.io.IOException: Could not parse SOAP message. Remaining stream ...
at weblogic.wsee.ws.dispatch.client.ConnectionHandler.handleResponse(ConnectionHandler.java:181)
at weblogic.wsee.handler.HandlerIterator.handleResponse(HandlerIterator.java:287)
at weblogic.wsee.handler.HandlerIterator.handleResponse(HandlerIterator.java:271)
... 6 more
Caused by: java.io.IOException: Could not parse SOAP message. Remaining stream ...
at weblogic.wsee.connection.soap.SoapConnection.receive(SoapConnection.java:521)
at weblogic.wsee.ws.dispatch.client.ConnectionHandler.handleResponse(ConnectionHandler.java:179)
... 8 more
Caused by: weblogic.xml.saaj.VersionMismatchException: unable to locate Envelope in namespace http://schemas.xmlsoap.org/soap/envelope/. Root element is "http://schemas.xmlsoap.org/wsdl/" in namespace "definitions"
at weblogic.xml.saaj.SaajDocument.getEnvelope(SaajDocument.java:107)
at weblogic.xml.saaj.SOAPPartImpl.envelope(SOAPPartImpl.java:77)
at weblogic.xml.saaj.SOAPPartImpl.getEnvelope(SOAPPartImpl.java:72)
at weblogic.xml.saaj.SOAPMessageImpl.<init>(SOAPMessageImpl.java:156)
at weblogic.xml.saaj.MessageFactoryImpl.createMessage(MessageFactoryImpl.java:76)
at weblogic.wsee.connection.soap.SoapClientConnection.createSOAPMessage(SoapClientConnection.java:134)
at weblogic.wsee.connection.soap.SoapConnection.receive(SoapConnection.java:515)
 
Vijitha Kumara
Bartender
Posts: 3914
9
Chrome Fedora Hibernate
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
What is your scenario, you need to provide more details on about your code etc...
 
SaravanaKumar Venugopal
Greenhorn
Posts: 23
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I am trying to consume a remedy web service, for which I have used ant clientgen task to generate jar file. After jar file generation I have added in classpath and called the function of the remedy web service, on calling the service I am getting the below given exception. Below given is the sample example by calling service,


HelloService_PortType port = null;
HelloService_PortType_Stub stub = null;

String wsdl = "http://localhost/WSDL/public/HelloService?wsdl";

HelloService_V1Service_Impl locator = new HelloService_V1Service_Impl(wsdl);

port = locator.HelloService_V1Soap("username", "password");
stub = (HelloService_V1PortType_Stub) port;

String endPt = wsdl.substring(0,
wsdl.length() - "?wsdl".length());

stub._setProperty(HelloService_PortType_Stub.ENDPOINT_ADDRESS_PROPERTY, endPt);

GetInputMap map = new GetInputMap();
map.setID("TestUser");

//System.out.println(locator);
GetOutputMap OMap = port.opGet(map); // Place where the exception got trigerred
 
SaravanaKumar Venugopal
Greenhorn
Posts: 23
  • Likes 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Issue has been ressoved by having an handler class for WSDl file, since the remedy SOAP header has not been identified for JAX-RPC, so we had added an handler class which has fixed the issue.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic