Error while passing xml tags in SOAP UI while testing WSDL
Hi,
I am facing error while passing the xml tags inside the <xml> tag while testing the SOAP wsdl from SOAP UI
syntax that i am using:
<soapenv:Envelope xmlns:fil="http://FileReceived" xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/">
<soapenv:Header>
<wsse:Security soapenv:mustUnderstand="1" xmlns:wsse="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd" xmlns:wsu="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd">
<wsse:UsernameToken wsu:Id="UsernameToken-8FC8AF46F90DFE59D316125055920301">
<wsse:Username>suresh</wsse:Username>
<wsse:Password Type="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-username-token-profile-1.0#PasswordText">suresh</wsse:Password>
<wsse:Nonce EncodingType="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-soap-message-security-1.0#Base64Binary">RkLg909bHec9nKy6AhRNKA==</wsse:Nonce>
<wsu:Created>2021-02-05T06:13:12.011Z</wsu:Created>
</wsse:UsernameToken>
</wsse:Security>
</soapenv:Header>
<soapenv:Body>
<fil:processFileReceived>
<fileId>AMR</fileId>
<xml>
<test>abc</test>
</xml>
<!--Optional:-->
<arg2>7204C2FE-13B1-4A48-8CDA-DE8386C60EF9</arg2>
</fil:processFileReceived>
</soapenv:Body>
</soapenv:Envelope>
Error:
<S:Envelope xmlns:S="http://schemas.xmlsoap.org/soap/envelope/">
<S:Body>
<S:Fault xmlns:ns4="http://www.w3.org/2003/05/soap-envelope">
<faultcode>S:Server</faultcode>
<faultstring>Call to parse xml failed.
org.dom4j.DocumentException: Error on line 2 of document : Premature end of file.</faultstring>
<detail>
<ns2:exception class="javax.xml.ws.soap.SOAPFaultException" note="To disable this feature, set com.sun.xml.ws.fault.SOAPFaultBuilder.disableCaptureStackTrace system property to false" xmlns:ns2="http://jax-ws.dev.java.net/">
<message>Call to parse xml failed.
org.dom4j.DocumentException: Error on line 2 of document : Premature end of file.</message>
<ns2:stackTrace>
<ns2:frame class="com.adminserver.webservice.helper.WebServiceHelper" file="WebServiceHelper.java" line="207" method="createSOAPFault"/>
<ns2:frame class="com.adminserver.webservice.helper.WebServiceHelper" file="WebServiceHelper.java" line="167" method="createSOAPFault"/>
<ns2:frame class="com.adminserver.pas.webservice.bll.filereceived.FileReceivedExecutor" file="FileReceivedExecutor.java" line="39" method="processFile"/>
<ns2:frame class="com.adminserver.pas.webservice.bll.filereceived.PasFileReceived" file="PasFileReceived.java" line="55" method="processFileReceived"/>
<ns2:frame class="sun.reflect.NativeMethodAccessorImpl" file="NativeMethodAccessorImpl.java" line="native" method="invoke0"/>
<ns2:frame class="sun.reflect.NativeMethodAccessorImpl" file="NativeMethodAccessorImpl.java" line="62" method="invoke"/>
<ns2:frame class="sun.reflect.DelegatingMethodAccessorImpl" file="DelegatingMethodAccessorImpl.java" line="43" method="invoke"/>
<ns2:frame class="java.lang.reflect.Method" file="Method.java" line="498" method="invoke"/>
<ns2:frame class="com.sun.xml.ws.api.server.InstanceResolver$1" file="InstanceResolver.java" line="246" method="invoke"/>
<ns2:frame class="com.sun.xml.ws.server.InvokerTube$2" file="InvokerTube.java" line="146" method="invoke"/>
<ns2:frame class="com.sun.xml.ws.server.sei.EndpointMethodHandler" file="EndpointMethodHandler.java" line="257" method="invoke"/>
<ns2:frame class="com.sun.xml.ws.server.sei.SEIInvokerTube" file="SEIInvokerTube.java" line="95" method="processRequest"/>
<ns2:frame class="com.sun.xml.ws.api.pipe.Fiber" file="Fiber.java" line="629" method="__doRun"/>
<ns2:frame class="com.sun.xml.ws.api.pipe.Fiber" file="Fiber.java" line="588" method="_doRun"/>
<ns2:frame class="com.sun.xml.ws.api.pipe.Fiber" file="Fiber.java" line="573" method="doRun"/>
<ns2:frame class="com.sun.xml.ws.api.pipe.Fiber" file="Fiber.java" line="470" method="runSync"/>
<ns2:frame class="com.sun.xml.ws.server.WSEndpointImpl$2" file="WSEndpointImpl.java" line="295" method="process"/>
<ns2:frame class="com.sun.xml.ws.transport.http.HttpAdapter$HttpToolkit" file="HttpAdapter.java" line="519" method="handle"/>
<ns2:frame class="com.sun.xml.ws.transport.http.HttpAdapter" file="HttpAdapter.java" line="288" method="handle"/>
<ns2:frame class="com.sun.xml.ws.transport.http.servlet.ServletAdapter" file="ServletAdapter.java" line="143" method="handle"/>
<ns2:frame class="com.sun.xml.ws.transport.http.servlet.WSServletDelegate" file="WSServletDelegate.java" line="155" method="doGet"/>
<ns2:frame class="com.sun.xml.ws.transport.http.servlet.WSServletDelegate" file="WSServletDelegate.java" line="189" method="doPost"/>
<ns2:frame class="com.sun.xml.ws.transport.http.servlet.WSServlet" file="WSServlet.java" line="76" method="doPost"/>
<ns2:frame class="sun.reflect.NativeMethodAccessorImpl" file="NativeMethodAccessorImpl.java" line="native" method="invoke0"/>
<ns2:frame class="sun.reflect.NativeMethodAccessorImpl" file="NativeMethodAccessorImpl.java" line="62" method="invoke"/>
<ns2:frame class="sun.reflect.DelegatingMethodAccessorImpl" file="DelegatingMethodAccessorImpl.java" line="43" method="invoke"/>
<ns2:frame class="java.lang.reflect.Method" file="Method.java" line="498" method="invoke"/>
<ns2:frame class="com.adminserver.web.helper.WSServlet" file="WSServlet.java" line="93" method="doPost"/>
<ns2:frame class="javax.servlet.http.HttpServlet" file="HttpServlet.java" line="648" method="service"/>
<ns2:frame class="javax.servlet.http.HttpServlet" file="HttpServlet.java" line="729" method="service"/>
<ns2:frame class="org.apache.catalina.core.ApplicationFilterChain" file="ApplicationFilterChain.java" line="231" method="internalDoFilter"/>
<ns2:frame class="org.apache.catalina.core.ApplicationFilterChain" file="ApplicationFilterChain.java" line="166" method="doFilter"/>
<ns2:frame class="org.apache.tomcat.websocket.server.WsFilter" file="WsFilter.java" line="53" method="doFilter"/>
<ns2:frame class="org.apache.catalina.core.ApplicationFilterChain" file="ApplicationFilterChain.java" line="193" method="internalDoFilter"/>
<ns2:frame class="org.apache.catalina.core.ApplicationFilterChain" file="ApplicationFilterChain.java" line="166" method="doFilter"/>
<ns2:frame class="com.github.ziplet.filter.compression.CompressingFilter" file="CompressingFilter.java" line="263" method="doFilter"/>
<ns2:frame class="org.apache.catalina.core.ApplicationFilterChain" file="ApplicationFilterChain.java" line="193" method="internalDoFilter"/>
<ns2:frame class="org.apache.catalina.core.ApplicationFilterChain" file="ApplicationFilterChain.java" line="166" method="doFilter"/>
<ns2:frame class="com.oracle.pas.filter.SecurityFilter" file="SecurityFilter.java" line="57" method="doFilter"/>
<ns2:frame class="org.apache.catalina.core.ApplicationFilterChain" file="ApplicationFilterChain.java" line="193" method="internalDoFilter"/>
<ns2:frame class="org.apache.catalina.core.ApplicationFilterChain" file="ApplicationFilterChain.java" line="166" method="doFilter"/>
<ns2:frame class="com.thetransactioncompany.cors.CORSFilter" file="CORSFilter.java" line="209" method="doFilter"/>
<ns2:frame class="com.thetransactioncompany.cors.CORSFilter" file="CORSFilter.java" line="244" method="doFilter"/>
<ns2:frame class="org.apache.catalina.core.ApplicationFilterChain" file="ApplicationFilterChain.java" line="193" method="internalDoFilter"/>
<ns2:frame class="org.apache.catalina.core.ApplicationFilterChain" file="ApplicationFilterChain.java" line="166" method="doFilter"/>
<ns2:frame class="org.apache.catalina.core.StandardWrapperValve" file="StandardWrapperValve.java" line="202" method="invoke"/>
<ns2:frame class="org.apache.catalina.core.StandardContextValve" file="StandardContextValve.java" line="96" method="invoke"/>
<ns2:frame class="org.apache.tomee.catalina.OpenEJBValve" file="OpenEJBValve.java" line="45" method="invoke"/>
<ns2:frame class="org.apache.catalina.authenticator.AuthenticatorBase" file="AuthenticatorBase.java" line="541" method="invoke"/>
<ns2:frame class="org.apache.catalina.core.StandardHostValve" file="StandardHostValve.java" line="139" method="invoke"/>
<ns2:frame class="org.apache.catalina.valves.ErrorReportValve" file="ErrorReportValve.java" line="92" method="invoke"/>
<ns2:frame class="org.apache.tomee.catalina.OpenEJBSecurityListener$RequestCapturer" file="OpenEJBSecurityListener.java" line="97" method="invoke"/>
<ns2:frame class="org.apache.catalina.valves.AbstractAccessLogValve" file="AbstractAccessLogValve.java" line="678" method="invoke"/>
<ns2:frame class="org.apache.catalina.core.StandardEngineValve" file="StandardEngineValve.java" line="74" method="invoke"/>
<ns2:frame class="org.apache.catalina.ha.tcp.ReplicationValve" file="ReplicationValve.java" line="330" method="invoke"/>
<ns2:frame class="org.apache.catalina.connector.CoyoteAdapter" file="CoyoteAdapter.java" line="343" method="service"/>
<ns2:frame class="org.apache.coyote.http11.Http11Processor" file="Http11Processor.java" line="367" method="service"/>
<ns2:frame class="org.apache.coyote.AbstractProcessorLight" file="AbstractProcessorLight.java" line="65" method="process"/>
<ns2:frame class="org.apache.coyote.AbstractProtocol$ConnectionHandler" file="AbstractProtocol.java" line="860" method="process"/>
<ns2:frame class="org.apache.tomcat.util.net.NioEndpoint$SocketProcessor" file="NioEndpoint.java" line="1598" method="doRun"/>
<ns2:frame class="org.apache.tomcat.util.net.SocketProcessorBase" file="SocketProcessorBase.java" line="49" method="run"/>
<ns2:frame class="java.util.concurrent.ThreadPoolExecutor" file="ThreadPoolExecutor.java" line="1149" method="runWorker"/>
<ns2:frame class="java.util.concurrent.ThreadPoolExecutor$Worker" file="ThreadPoolExecutor.java" line="624" method="run"/>
<ns2:frame class="org.apache.tomcat.util.threads.TaskThread$WrappingRunnable" file="TaskThread.java" line="61" method="run"/>
<ns2:frame class="java.lang.Thread" file="Thread.java" line="748" method="run"/>
</ns2:stackTrace>
</ns2:exception>
</detail>
</S:Fault>
</S:Body>
</S:Envelope>
I am using TomEE as application server.
Please let me know in case of any information if required.