soap parsing wsdl error: Unexpected element: TAG_E

2019-02-21 15:00发布

I have an error importing a WSDL definition from an ASP.NET version 4 Visual Studio 2010 Express project, into SOAPUI 4.5.1

URL would be like

http://localhost:7929/ws/AX.asmx?WSDL

Error generated

Error loading [http://localhost:7929/ws/AX.asmx?WSDL]: org.apache.xmlbeans.XmlException:
org.apache.xmlbeans.XmlException: error: Unexpected element: TAG_END

Error trace:

com.eviware.soapui.impl.support.definition.support.InvalidDefinitionException
    at com.eviware.soapui.impl.wsdl.support.wsdl.WsdlLoader.loadXmlObject(WsdlLoader.java:138)
    at com.eviware.soapui.impl.wsdl.support.xsd.SchemaUtils.getDefinitionParts(SchemaUtils.java:535)
...

Any suggestions most welcome!

标签: wsdl soapui
4条回答
相关推荐>>
2楼-- · 2019-02-21 15:23

The issue is that soapui doesn't know where to find the schema file. If your wsdl is deployed to a server, it will return a url of the xsd file to include and soapui will be able to find it....

查看更多
家丑人穷心不美
3楼-- · 2019-02-21 15:31

I had the same issue with Soap UI 5.2.0

The solution for me was to turn off the proxy (as suggested by @user518066)

enter image description here

查看更多
Bombasti
4楼-- · 2019-02-21 15:33

Are you sure that the service is running? When debugging solutions with several WCF projects, there are times in which we could think that we are running the project we are working into and it turns not be that case. If you face an Error 404 when enter the svc url into a browser, then this could be the cause of the problem. In that scenario, SOAP UI will fail when trying to add or create a new WSDL endpoint. So, make sure that your solution starts running from the project where the target svc is located.

查看更多
仙女界的扛把子
5楼-- · 2019-02-21 15:45

I had the same problem, after several hours I found that the problem was about IPv6.

When I go to service URL I can see and validate the wsdl file. There was no problem at all.

http://localhost/SoapServer.php?wsdl

But when I add this URL to SoapUI it gives error Unexpected element: TAG_END. I found the reason by using cURL, curl http://localhost/SoapServer.php?wsdl returns 404!!

So realized that my Apache listens both IPv4 and IPv6, browser goes to IPv6 and gets the wsdl but cURL and SoapUI goes to IPv4 and get 404 error.

I disabled IPv6 on my Apache by removing the line Listen [::0]:80 in httpd.conf file, this solved the problem.

查看更多
登录 后发表回答