webservice wsdl axis2报错 Provider com.bea.xml.stream.MXParserFactory not found

错误信息:

Exception in thread "main" javax.xml.stream.FactoryConfigurationError: Provider com.bea.xml.stream.MXParserFactory not found
    at javax.xml.stream.FactoryFinder.newInstance(FactoryFinder.java:72)
    at javax.xml.stream.FactoryFinder.find(FactoryFinder.java:176)
    at javax.xml.stream.FactoryFinder.find(FactoryFinder.java:92)
    at javax.xml.stream.XMLInputFactory.newInstance(XMLInputFactory.java:136)
    at org.apache.axiom.om.util.StAXUtils$7.run(StAXUtils.java:504)
    at java.security.AccessController.doPrivileged(Native Method)
    at org.apache.axiom.om.util.StAXUtils.newXMLInputFactory(StAXUtils.java:494)
    at org.apache.axiom.om.util.StAXUtils.getXMLInputFactory_perClassLoader(StAXUtils.java:565)
    at org.apache.axiom.om.util.StAXUtils.getXMLInputFactory(StAXUtils.java:171)
    at org.apache.axiom.om.util.StAXUtils.getXMLInputFactory(StAXUtils.java:136)
    at org.apache.axiom.om.util.StAXUtils.createXMLStreamReader(StAXUtils.java:223)
    at org.apache.axiom.om.impl.llom.factory.AbstractOMMetaFactory.createXMLStreamReader(AbstractOMMetaFactory.java:53)
    at org.apache.axiom.om.impl.llom.factory.AbstractOMMetaFactory.createOMBuilder(AbstractOMMetaFactory.java:95)
    at org.apache.axiom.om.OMXMLBuilderFactory.createOMBuilder(OMXMLBuilderFactory.java:153)
    at org.apache.axiom.om.OMXMLBuilderFactory.createOMBuilder(OMXMLBuilderFactory.java:133)
    at org.apache.axiom.om.OMXMLBuilderFactory.createOMBuilder(OMXMLBuilderFactory.java:104)
    at org.apache.axis2.util.XMLUtils.toOM(XMLUtils.java:590)
    at org.apache.axis2.util.XMLUtils.toOM(XMLUtils.java:575)
    at org.apache.axis2.deployment.DescriptionBuilder.buildOM(DescriptionBuilder.java:97)
    at org.apache.axis2.deployment.AxisConfigBuilder.populateConfig(AxisConfigBuilder.java:90)
    at org.apache.axis2.deployment.DeploymentEngine.populateAxisConfiguration(DeploymentEngine.java:857)
    at org.apache.axis2.deployment.FileSystemConfigurator.getAxisConfiguration(FileSystemConfigurator.java:116)
    at org.apache.axis2.context.ConfigurationContextFactory.createConfigurationContext(ConfigurationContextFactory.java:64)
    at org.apache.axis2.context.ConfigurationContextFactory.createConfigurationContextFromFileSystem(ConfigurationContextFactory.java:210)
    at org.apache.axis2.client.ServiceClient.configureServiceClient(ServiceClient.java:151)
    at org.apache.axis2.client.ServiceClient.<init>(ServiceClient.java:144)
    at org.apache.axis2.client.ServiceClient.<init>(ServiceClient.java:251)
    at org.apache.axis2.rpc.client.RPCServiceClient.<init>(RPCServiceClient.java:48)
    at com.neusoft.ermsuite.css.sv.svac.svrequest.bo.test.main(test.java:17)

问题背景:

java main 中调用webservice wsdl

问题原因:
缺少jar包wstx-asl.jar

stax-api.jar

解决:
导入jar包

wstx-asl.jar,如果导入后仍然报错,请导入stax-api.jar

时间: 2024-08-09 21:05:58

webservice wsdl axis2报错 Provider com.bea.xml.stream.MXParserFactory not found的相关文章

解决调用WebService短信接口后报Provider com.sun.xml.stream.ZephyrParserFactory not found

Exception in thread "main" javax.xml.stream.FactoryFinder$ConfigurationError: Provider com.sun.xml.stream.ZephyrParserFactory not found at javax.xml.stream.FactoryFinder.newInstance(FactoryFinder.java:152) at javax.xml.stream.FactoryFinder.findJ

dom4j解析xml报错:Nested exception: org.xml.sax.SAXParseException: White space is required between the processing instruction target and data.

采用dom4j方式解析string类型的xml xml:        String string="<?xmlversion=\"1.0\" encoding=\"UTF-8\"?><ROOT><HEAD><INFO><BUSINESSNO>T065205072015000097</BUSINESSNO><BUSINESSTYPE>T</BUSINESSTYPE&g

用XmlSerializer进行xml反序列化的时候,程序报错: 不应有 &lt;xml xmlns=&#39;&#39;&gt;

原因 一,类型错误: 比如xml本来是UserInfo类型 用XmlSerializer进行反序列化传入的类型是MemberInfo这就会报错 二,xml根节点和对象的类名不一致,而又没有对类加入[XmlRoot(Namespace = "",IsNullable = false,ElementName = "RequestResult")]限制 用XmlSerializer进行xml反序列化的时候,程序报错: 不应有 <xml xmlns=''>

IDEA导入springboot项目报错:non-managed pom.xml file found

用IDEA打开了一个maven项目,竟然报错:Non-managed pom.xml file found.结果显示如下b样: 第一步:点击侧边maven视图 第二步:添加pom.xml文件 第三步:选择项目运行所需sdk(即jdk) 依次点击file->project structure,打开配置界面 原文地址:https://www.cnblogs.com/zouhong/p/12375218.html

C# 项目引用WebService,提示报错“在 ServiceModel 客户端配置部分中,找不到引用协定...”

项目情况:C# 类库项目里引用了WebService,Web层调用类库,将返回的Json结果在Web界面展示 在类库添加了服务引用,命名为:XSystemWebservice,在代码中使用: XSystemWebservice.XSystemWebserviceSoapClient r = new XSystemWebserviceSoapClient();                 string result = r.ReturnDocStatus(DocID); 调试过程报错:在 Se

如果Laravel 报错 file_put_contents(): failed to open stream

问题解决方法 执行命令 php artisan cache:clear 并赋予 /storage 文件夹读写权限: chmod -R 777 storage: 若在执行 php artisan cache:clear 时出现错误:Uncaught UnexpectedValueException: The stream or file "/storage/logs/laravel.log" could not be opened: failed to open stream: Perm

Maven 项目报错 java.httpservlet 和synchronized使用

使用java8 的lanmbe表达式时,使用java1.8编译,则会报错 需要在pom.xml的<bulid></build>中添加 <plugins> <plugin> <groupId>org.apache.maven.plugins</groupId> <artifactId>maven-compiler-plugin</artifactId> <version>2.3.2</versi

com.intellij.javaee.oss.admin.jmx.JmxAdminException: com.intellij.execution.ExecutionException idea 导出war 报错

com.intellij.javaee.oss.admin.jmx.JmxAdminException: com.intellij.execution.ExecutionException 部署到intellij IDEA13上面,容器是tomcat7,IDEA配置两个artifacts包,一个是war,一个是exploded.当我用tomcat使用exploded包运行的时候,可以运行,但是使用war包的时候却报错. 在web.xml中加入下面这段话就行了: <context-param>

maven创建web项目的报错解决方案

在学习maven模块化构建项目的时候遇到了如下报错信息: web.xml is missing and <failOnMissingWebXml> is set to true .这时候需要右击项目-->Java EE Tools-->Generate Deployment Descriptor Stub.然后系统会在src/main/webapp/WEB_INF文件加下创建web.xml文件.错误解决! 如果你的工程不是web项目,那么还有另外一种解决方案,就是在pom文件中配置