Apache CXF和spring集成配置有关问题请问大神
Apache CXF和spring集成配置问题请教大神
下面配置中的 <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-servlet.xml" />
三个文件从哪里获得?
------解决方案--------------------
把你的cxf的jar包打开下的 META-INF/cxf/ 这个路径下
下面配置中的 <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-servlet.xml" />
三个文件从哪里获得?
- XML code
<?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:jaxws="http://cxf.apache.org/jaxws" xsi:schemaLocation=" http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans.xsd http://cxf.apache.org/jaxws http://cxf.apache.org/schemas/jaxws.xsd"> <!-- Import Apache CXF Bean Definition --> <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-servlet.xml" /> <!-- SurveyService --> <bean id="surveyService" class="ws.cxf.impl.SurveyService"> <property name="excludeName" value="Michael" /> <property name="leastPonit" value="10" /> </bean> <!-- Expose SurveyWebService --> <jaxws:server id="surveyWebService" serviceClass="ws.cxf.ISurveyService" address="/SurveyWebService"> <jaxws:serviceBean> <ref bean="surveyService" /> <!-- 要暴露的 bean 的引用 --> </jaxws:serviceBean> </jaxws:server> </beans>
------解决方案--------------------
把你的cxf的jar包打开下的 META-INF/cxf/ 这个路径下