hayes_shi 2014-07-21 07:25 采纳率: 0%
浏览 1981

基于cxf-webservice的项目业务分离,cxf客户端jar包冲突

现在项目做业务的分离,webservice接口是基于apache cxf实现的,以及生成客户端。因为项目彼此间有不同业务的调用,所以打的客户端jar包有很多class类会冲突
冲突提示如下:
Caused by: org.apache.cxf.service.factory.ServiceConstructionException
at org.apache.cxf.jaxb.JAXBDataBinding.initialize(JAXBDataBinding.java:338)
at org.apache.cxf.service.factory.AbstractServiceFactoryBean.initializeDataBindings(AbstractServiceFactoryBean.java:86)
at org.apache.cxf.service.factory.ReflectionServiceFactoryBean.buildServiceFromClass(ReflectionServiceFactoryBean.java:490)
。。。。。。。
Caused by: com.sun.xml.bind.v2.runtime.IllegalAnnotationsException: 19 counts of IllegalAnnotationExceptions
。。。。。。
Two classes have the same XML type name "{http://inner.cxf.com/}wsPolicyData". Use @XmlType.name and @XmlType.namespace to assign different names to them.
this problem is related to the following location:
at com.cxf.client.outserver.WsPolicyData
at protected com.cxf.client.outserver.WsPolicyData com.cxf.client.outserver.WsSeatWithPriceAndComisionItem.policyData
at com.cxf.client.outserver.WsSeatWithPriceAndComisionItem
at protected java.util.List com.cxf.client.outserver.WsFlightWithPriceAndCommision.seatItems
at com.cxf.client.outserver.WsFlightWithPriceAndCommision
at protected java.util.List com.cxf.client.outserver.WsFlightWithPriceAndCommisionItem.flights
at com.cxf.client.outserver.WsFlightWithPriceAndCommisionItem
at protected java.util.List com.cxf.client.outserver.AvailableFlightWithPriceAndCommisionReply.flightItems
at com.cxf.client.outserver.AvailableFlightWithPriceAndCommisionReply
at @javax.xml.bind.annotation.XmlSeeAlso(value=[class com.yl.domain.PublicOfTicketMsg, class com.yl.domain.PublicOfStore, class com.yl.cxf.domain.PublicOfWebTicket, class com.yl.domain.PublicOfPagination, class com.yl.domain.PublicOfTicket, class com.yl.domain.PublicOfMessageDomain, class com.yl.cxf.domain.PublicOfWebMerchant, class com.cxf.client.outserver.AvailableFlightWithPriceAndCommisionReply, class com.cxf.order.PyAccount, class com.cxf.client.outserver.TcGetSceneryTrafficInfoResponse, class com.cxf.client.outserver.TcGetSceneryResponse, class com.cxf.client.outserver.ArrayOfTcSimpleScenery, class com.cxf.client.outserver.ArrayOfTcTheme, class com.cxf.client.outserver.ArrayOfTcImpression, class com.cxf.client.outserver.ArrayOfTcSuitherd, class com.cxf.client.outserver.TcSimpleScenery, class com.yl.cxf.domain.PublicOfWebMerchant, class java.util.ArrayList, class com.cxf.client.outserver.AvailableFlightWithPriceAndCommisionReply, class com.cxf.order.PyAccount, class com.cxf.client.outserver.TcGetSceneryTrafficInfoResponse, class com.yl.domain.UnionPayOrder, class com.yl.core.page.PublicOfPager])
at private com.yl.cxf.domain.PublicOutDomain com.yl.cxf.publicservice.jaxws_asm.DoAccquireRefundResponse._return
at com.yl.cxf.publicservice.jaxws_asm.DoAccquireRefundResponse
this problem is related to the following location:
at com.cxf.order.WsPolicyData
at protected com.cxf.order.WsPolicyData com.cxf.order.WsSeatWithPriceAndComisionItem.policyData
at com.cxf.order.WsSeatWithPriceAndComisionItem
at protected java.util.List com.cxf.order.WsFlightWithPriceAndCommision.seatItems
at com.cxf.order.WsFlightWithPriceAndCommision
at protected java.util.List com.cxf.order.WsFlightWithPriceAndCommisionItem.flights
at com.cxf.order.WsFlightWithPriceAndCommisionItem
at protected java.util.List com.cxf.order.AvailableFlightWithPriceAndCommisionReply.flightItems
at com.cxf.order.AvailableFlightWithPriceAndCommisionReply
at protected com.cxf.order.AvailableFlightWithPriceAndCommisionReply com.cxf.order.GetAvailableFlightResponse._return
at com.cxf.order.GetAvailableFlightResponse
at public com.cxf.order.GetAvailableFlightResponse com.cxf.order.ObjectFactory.createGetAvailableFlightResponse()
at com.cxf.order.ObjectFactory
不知道大家做项目分离时,有没有遇到过此类问题,以及解决方法,希望大家能指教一二。

  • 写回答

1条回答 默认 最新

  • CSDN-Ada助手 CSDN-AI 官方账号 2022-09-21 01:54
    关注
    不知道你这个问题是否已经解决, 如果还没有解决的话:

    如果你已经解决了该问题, 非常希望你能够分享一下解决方案, 写成博客, 将相关链接放在评论区, 以帮助更多的人 ^-^
    评论

报告相同问题?

悬赏问题

  • ¥50 易语言把MYSQL数据库中的数据添加至组合框
  • ¥20 求数据集和代码#有偿答复
  • ¥15 关于下拉菜单选项关联的问题
  • ¥20 java-OJ-健康体检
  • ¥15 rs485的上拉下拉,不会对a-b<-200mv有影响吗,就是接受时,对判断逻辑0有影响吗
  • ¥15 使用phpstudy在云服务器上搭建个人网站
  • ¥15 应该如何判断含间隙的曲柄摇杆机构,轴与轴承是否发生了碰撞?
  • ¥15 vue3+express部署到nginx
  • ¥20 搭建pt1000三线制高精度测温电路
  • ¥15 使用Jdk8自带的算法,和Jdk11自带的加密结果会一样吗,不一样的话有什么解决方案,Jdk不能升级的情况