<?xml version="1.0" encoding="UTF-8"?>
<beans xmlns="http://www.springframework.org/schema/beans"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:cxf="http://cxf.apache.org/core"
xmlns:soap="http://cxf.apache.org/bindings/soap"
xmlns:jaxws="http://cxf.apache.org/jaxws"
xmlns:jms="http://cxf.apache.org/transports/jms"
xmlns:p="http://www.springframework.org/schema/p"
xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans.xsd
http://cxf.apache.org/core http://cxf.apache.org/schemas/core.xsd
http://cxf.apache.org/bindings/soap http://cxf.apache.org/schema/bindings/soap.xsd
http://cxf.apache.org/jaxws http://cxf.apache.org/schemas/jaxws.xsd
http://cxf.apache.org/transports/jms http://cxf.apache.org/schemas/configuration/jms.xsd">
<import resource="classpath:META-INF/cxf/cxf.xml" />
<import resource="classpath:META-INF/cxf/cxf-extension-soap.xml" />
<import resource="classpath:META-INF/cxf/cxf-extension-local.xml" />
<import resource="classpath:META-INF/cxf/cxf-extension-http.xml" />
<import resource="classpath:META-INF/cxf/cxf-servlet.xml" />
<import resource="classpath:META-INF/cxf/cxf-extension-jms.xml" />
<bean id="propertyConfigurer"
class="org.springframework.beans.factory.config.PropertyPlaceholderConfigurer">
<property name="locations">
<list>
<value>classpath:config.properties</value>
</list>
</property>
</bean>
<!-- GTMSShrccAcctService -->
<jms:conduit
name="{http://swift.service.srcb.com/abstraction/atomic/technical.SendMsg2MpsService/v1}SendMsg2MpsServicePort.jms-conduit">
<jms:clientConfig clientReceiveTimeout="60000" />
<jms:sessionPool lowWaterMark="5" highWaterMark="80" />
<jms:address destinationStyle="queue"
jndiConnectionFactoryName="${SendMsg2Mps.jndiConnectionFactoryName}" jndiDestinationName="${SendMsg2Mps.jndiDestinationName}"
jndiReplyDestinationName="${SendMsg2Mps.jndiReplyDestinationName}">
<jms:JMSNamingProperty name="java.naming.factory.initial"
value="com.sun.jndi.fscontext.RefFSContextFactory" />
<jms:JMSNamingProperty name="java.naming.provider.url"
value="${JMSNamingPropertyValue}" />
</jms:address>
</jms:conduit>
<jaxws:client id="SendMsg2MpsClient"
xmlns:s="http://swift.service.srcb.com/abstraction/atomic/technical.SendMsg2MpsService/v1"
serviceClass="com.amerisia.ebills.peripheryInterface.client.SendMsg2MpsClient.v1.SendMsg2MpsServicePortType"
serviceName="s:SendMsg2MpsService"
endpointName="s:SendMsg2MpsServicePort"
wsdlLocation="file:src/resourcesWsdl/SWIFT_EBILLS_Client/SendMsg2MpsService.wsdl"
address="jms:/">
<jaxws:properties>
<!-- 修改默认的SOAP编码 -->
<entry key="org.apache.cxf.message.Message.ENCODING"
value="utf-8" />
</jaxws:properties>
<!-- 增加日志特征 -->
<jaxws:features>
<bean class="org.apache.cxf.feature.LoggingFeature" />
</jaxws:features>
</jaxws:client>
</beans>
简单的java类main函数访问
static ApplicationContext context=new ClassPathXmlApplicationContext("resourcesXml/ApplicationContext_jms_SendMsg2MpsClient.xml");
报错:还弹出对话框:
java.lang.ExceptionInInitializerError
Caused by: org.springframework.beans.factory.BeanDefinitionStoreException: Line 13 in XML document from class path resource [com/amerisia/ebills/peripheryInterface/client/resourcesXml/ApplicationContext_jms_SendMsg2MpsClient.xml] is invalid; nested exception is org.xml.sax.SAXParseException: Element type "beans" must be declared.
at org.springframework.beans.factory.xml.XmlBeanDefinitionReader.loadBeanDefinitions(XmlBeanDefinitionReader.java:135)
at org.springframework.context.support.AbstractXmlApplicationContext.loadBeanDefinitions(AbstractXmlApplicationContext.java:144)
at org.springframework.context.support.AbstractXmlApplicationContext.refreshBeanFactory(AbstractXmlApplicationContext.java:79)
at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:249)
at org.springframework.context.support.ClassPathXmlApplicationContext.<init>(ClassPathXmlApplicationContext.java:80)
at org.springframework.context.support.ClassPathXmlApplicationContext.<init>(ClassPathXmlApplicationContext.java:65)
at org.springframework.context.support.ClassPathXmlApplicationContext.<init>(ClassPathXmlApplicationContext.java:56)
at com.amerisia.ebills.peripheryInterface.client.SendMsg2MpsClient.v1.SendMsg2MpsServicePortType_SendMsg2MpsServicePort_Client.<clinit>(SendMsg2MpsServicePortType_SendMsg2MpsServicePort_Client.java:37)
Caused by: org.xml.sax.SAXParseException: Element type "beans" must be declared.
at org.apache.xerces.framework.XMLParser.reportError(XMLParser.java:1213)
at org.apache.xerces.validators.common.XMLValidator.reportRecoverableXMLError(XMLValidator.java:1807)
at org.apache.xerces.validators.common.XMLValidator.validateElementAndAttributes(XMLValidator.java:3633)
at org.apache.xerces.validators.common.XMLValidator.callStartElement(XMLValidator.java:1229)
at org.apache.xerces.framework.XMLDocumentScanner.scanElement(XMLDocumentScanner.java:1806)
at org.apache.xerces.framework.XMLDocumentScanner$ContentDispatcher.dispatch(XMLDocumentScanner.java:949)
at org.apache.xerces.framework.XMLDocumentScanner.parseSome(XMLDocumentScanner.java:381)
at org.apache.xerces.framework.XMLParser.parse(XMLParser.java:1098)
at org.apache.xerces.jaxp.DocumentBuilderImpl.parse(DocumentBuilderImpl.java:195)
at javax.xml.parsers.DocumentBuilder.parse(DocumentBuilder.java:98)
at org.springframework.beans.factory.xml.XmlBeanDefinitionReader.loadBeanDefinitions(XmlBeanDefinitionReader.java:128)
... 7 more
求解决方案????
- 大小: 7.6 KB
分享到:
相关推荐
java.lang.ExceptionInInitializerError异常的解决方法 java.lang.ExceptionInInitializerError异常是一种常见的Java异常,它发生在静态变量的初始化过程中。了解这个异常的解决方法对于Java开发者来说非常重要。 ...
总结来说,解决 `java.lang.ExceptionInInitializerError` 的关键步骤包括: 1. 查看错误堆栈跟踪,找到原始异常。 2. 分析引发异常的代码,通常是静态初始化块或静态变量初始化过程。 3. 修复导致异常的代码,确保...
Android studio报java.lang.ExceptionInInitializerError错误解决方法 一、Java.lang.ExceptionInInitializerError错误概述 Java.lang.ExceptionInInitializerError是一个非常常见的错误,在Android studio中经常...
`java.lang.ExceptionInInitializerError` 是Java编程语言中一种比较特殊的异常,通常在类的静态初始化过程中遇到问题时抛出。这个错误意味着在初始化类的静态变量或静态初始化块(static block)时发生了异常。这类...
"java.lang.NoClassDefFoundError错误解决办法" java.lang.NoClassDefFoundError错误是一种常见的Java错误,它发生在Java虚拟机在编译时能找到合适的类,而在运行时不能找到合适的类导致的错误。下面是该错误的解决...
Exception in thread "Thread-1" java.lang.ExceptionInInitializerError at com.semaphore.jna.md.MDLibrary.<clinit>(MDLibrary.java:39) at ...
java.lang.ExceptionInInitializerError Caused by: java.lang.IllegalArgumentException: input == null! at javax.imageio.ImageIO.read(ImageIO.java:1388) at com.pleanwar.fiying.FlyingObject.loadImage...
项目中碰到的,记录一下解决方案
链接is unknown to this NavController
类似的问题还包括其他类型的Java运行时异常,如`ExceptionInInitializerError`、`NoSuchMethodError`和`UnsatisfiedLinkError`等,这些错误通常与类加载、方法调用或库链接失败有关。解决这些问题通常需要深入理解...
java.lang.ExceptionInInitializerError 是一种初始化程序错误,指的是在程序中执行静态初始化程序时出现的异常。 19. java.lang.IllegalAccessError 违法访问错误 java.lang.IllegalAccessError 是一种违法访问...
### 知识点详解:Java.lang.ThreadLocal 类 #### 一、概述 **ThreadLocal** 并非线程的一种特殊实现形式,而是一种为每个线程提供独立副本的机制,通常被称为“线程局部变量”。这种机制使得每个线程都可以独立...
context with path [] threw exception [org.glassfish.jersey.server.ContainerException: java.lang.ExceptionInInitializerError: Native library sapjco3 is too old. Found library C:\Windows\System32\sapjco...
- **`java.lang.ExceptionInInitializerError`**:当执行类的静态初始化程序过程中发生异常时抛出。 - **`java.lang.SecurityException`**:违反安全原则异常,例如尝试执行未授权的操作。 - **`java.io.EOF...
而Dubbo作为阿里巴巴开源的RPC框架,主要解决的是服务之间的通信问题,提供了服务治理、监控等一系列功能。 整合Spring Boot和Dubbo的第一步是添加依赖。在`pom.xml`文件中,我们需要引入Spring Boot的父依赖和...
在Java编程语言中,异常处理机制通过try-catch-finally语句块实现。当一个异常在try块中发生时,控制权会立即传递给相应的catch块,使得开发者有机会处理这个异常,而不是让程序崩溃。如果捕获到的异常类型与catch块...
错误信息"无法解析运行时描述符: java.lang.IllegalStateException: MASM0001:"指出在部署Web服务时遇到了异常情况。这个错误代码MASM0001通常与WebLogic的模块组装(Module Assembly)过程有关,该过程是将应用组件...