cxf-spring-service.xml 4.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108
  1. <?xml version="1.0" encoding="UTF-8"?>
  2. <beans xmlns="http://www.springframework.org/schema/beans"
  3. xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:tx="http://www.springframework.org/schema/tx"
  4. xmlns:context="http://www.springframework.org/schema/context"
  5. xmlns:aop="http://www.springframework.org/schema/aop" xmlns:jaxws="http://cxf.apache.org/jaxws"
  6. xmlns:jaxrs="http://cxf.apache.org/jaxrs"
  7. xmlns:http-conf="http://cxf.apache.org/transports/http/configuration"
  8. xsi:schemaLocation="
  9. http://www.springframework.org/schema/context
  10. http://www.springframework.org/schema/context/spring-context-3.1.xsd
  11. http://www.springframework.org/schema/aop
  12. http://www.springframework.org/schema/aop/spring-aop-3.1.xsd
  13. http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-3.1.xsd
  14. http://www.springframework.org/schema/tx http://www.springframework.org/schema/tx/spring-tx-3.1.xsd
  15. http://cxf.apache.org/jaxws http://cxf.apache.org/schemas/jaxws.xsd
  16. http://cxf.apache.org/jaxrs http://cxf.apache.org/schemas/jaxrs.xsd
  17. http://cxf.apache.org/transports/http/configuration http://cxf.apache.org/schemas/configuration/http-conf.xsd">
  18. <import resource="classpath:META-INF/cxf/cxf.xml"/>
  19. <import resource="classpath:META-INF/cxf/cxf-servlet.xml"/>
  20. <!--
  21. <jaxws:endpoint id="cxfws" implementor="com.cxfws.ws.CxfwsImpl" address="/cxfws"/>
  22. <jaxws:endpoint id="cxfws"
  23. implementor="com.cxfws.ws.CxfwsImpl" address="/cxfwsService">
  24. <jaxws:features>
  25. <bean class="org.apache.cxf.feature.LoggingFeature" />
  26. </jaxws:features>
  27. </jaxws:endpoint>
  28. -->
  29. <!-- http://127.0.0.1:8080/znjg/service/userWebService?wsdl -->
  30. <jaxws:endpoint id="userWebService"
  31. implementor="com.jsjty.web.service.impl.UserWebService" address="/userWebService">
  32. <jaxws:features>
  33. <bean class="org.apache.cxf.feature.LoggingFeature" />
  34. </jaxws:features>
  35. </jaxws:endpoint>
  36. <!--
  37. <http-conf:conduit name="*.http-conduit">
  38. <http-conf:client ConnectionTimeout="5000" ReceiveTimeout="10000"/>
  39. </http-conf:conduit>
  40. -->
  41. <jaxws:client id="localhostUserClient" serviceClass="com.jsjty.web.service.IUserWebService" address="http://localhost:8081/znjg/service/userWebService">
  42. <jaxws:outInterceptors>
  43. <bean class="org.apache.cxf.interceptor.LoggingOutInterceptor"></bean>
  44. </jaxws:outInterceptors>
  45. </jaxws:client>
  46. <jaxws:client id="oaUserClient" serviceClass="com.jsjty.web.client.OAUserWebService" address="http://10.1.30.50:8083/gkoa/services/userWebService">
  47. <jaxws:outInterceptors>
  48. <bean class="org.apache.cxf.interceptor.LoggingOutInterceptor"></bean>
  49. </jaxws:outInterceptors>
  50. </jaxws:client>
  51. <jaxws:client id="jsjyUserClient" serviceClass="com.jsjty.web.client.JsjyUserWebService" address="http://10.1.30.117:18089/userService">
  52. <jaxws:outInterceptors>
  53. <bean class="org.apache.cxf.interceptor.LoggingOutInterceptor"></bean>
  54. </jaxws:outInterceptors>
  55. </jaxws:client>
  56. <jaxws:client id="aqUserClient" serviceClass="com.jsjty.web.client.AQUserWebService" address="http://10.1.30.114:8089/userNoHandlerService">
  57. <jaxws:outInterceptors>
  58. <bean class="org.apache.cxf.interceptor.LoggingOutInterceptor"></bean>
  59. </jaxws:outInterceptors>
  60. </jaxws:client>
  61. <jaxws:client id="zyUserClient" serviceClass="com.jsjty.web.client.ZYUserWebService" address="http://10.1.30.115:8080/gkzy/ws/soap/user">
  62. <jaxws:outInterceptors>
  63. <bean class="org.apache.cxf.interceptor.LoggingOutInterceptor"></bean>
  64. </jaxws:outInterceptors>
  65. </jaxws:client>
  66. <!-- 客户端密码配置Bean定义
  67. <bean id="passwordCallback" class="com.jsjty.web.client.ClientValidateCallback">
  68. <property name="userMap">
  69. <map>
  70. <entry key="admin" value="098f6bcd4621d373cade4e832627b4f6" />
  71. </map>
  72. </property>
  73. </bean>
  74. <jaxws:client id="aqUserClient" serviceClass="com.jsjty.web.client.AQUserWebService"
  75. address="http://192.168.30.140:8088/userService">
  76. <jaxws:outInterceptors>
  77. <bean class="org.apache.cxf.ws.security.wss4j.WSS4JOutInterceptor">
  78. <property name="properties">
  79. <map>
  80. <entry key="action" value="UsernameToken" />
  81. <entry key="user" value="admin" />
  82. <entry key="passwordType" value="PasswordText" />
  83. <entry key="passwordCallbackRef" value-ref="passwordCallback" />
  84. </map>
  85. </property>
  86. </bean>
  87. </jaxws:outInterceptors>
  88. </jaxws:client>
  89. -->
  90. <!-- WebService
  91. <bean class="org.springframework.remoting.jaxws.SimpleJaxWsServiceExporter">
  92. <property name="baseAddress"
  93. value="http://${webService.url}:${webService.port}/" />
  94. </bean>
  95. -->
  96. </beans>