cxf-CXF WebService发布报错,各位大神请看下

问题描述

CXF WebService发布报错,各位大神请看下
只要在maven项目上加了下面这段代码发布webservice 就报错(我自己写的demo是正常的):

<!-- 要发布成webservice的bean -->

/jaxws:endpoint

错误信息:
2015-01-07 20:42:43981 ERROR (org.springframework.web.context.ContextLoader:319) - Context initialization failed
org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'org.apache.cxf.jaxws.EndpointImpl---938321254': Invocation of init method failed; nested exception is javax.xml.ws.WebServiceException: org.apache.cxf.service.factory.ServiceConstructionException
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1482)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:521)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:458)
at org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:295)
at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:223)
at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:292)
at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:194)
at org.springframework.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingletons(DefaultListableBeanFactory.java:626)
at org.springframework.context.support.AbstractApplicationContext.finishBeanFactoryInitialization(AbstractApplicationContext.java:932)
at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:479)
at org.springframework.web.context.ContextLoader.configureAndRefreshWebApplicationContext(ContextLoader.java:389)
at org.springframework.web.context.ContextLoader.initWebApplicationContext(ContextLoader.java:294)
at org.springframework.web.context.ContextLoaderListener.contextInitialized(ContextLoaderListener.java:112)
at org.apache.catalina.core.StandardContext.listenerStart(StandardContext.java:4973)
at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5467)
at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)
at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1559)
at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1549)
at java.util.concurrent.FutureTask.run(Unknown Source)
at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
at java.lang.Thread.run(Unknown Source)
Caused by: javax.xml.ws.WebServiceException: org.apache.cxf.service.factory.ServiceConstructionException
at org.apache.cxf.jaxws.EndpointImpl.doPublish(EndpointImpl.java:371)
at org.apache.cxf.jaxws.EndpointImpl.publish(EndpointImpl.java:251)
at org.apache.cxf.jaxws.EndpointImpl.publish(EndpointImpl.java:539)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.invokeCustomInitMethod(AbstractAutowireCapableBeanFactory.java:1608)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.invokeInitMethods(AbstractAutowireCapableBeanFactory.java:1549)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1479)
... 21 more
Caused by: org.apache.cxf.service.factory.ServiceConstructionException
at org.apache.cxf.jaxb.JAXBDataBinding.initialize(JAXBDataBinding.java:341)
at org.apache.cxf.service.factory.AbstractServiceFactoryBean.initializeDataBindings(AbstractServiceFactoryBean.java:86)
at org.apache.cxf.service.factory.ReflectionServiceFactoryBean.buildServiceFromClass(ReflectionServiceFactoryBean.java:490)
at org.apache.cxf.jaxws.support.JaxWsServiceFactoryBean.buildServiceFromClass(JaxWsServiceFactoryBean.java:704)
at org.apache.cxf.service.factory.ReflectionServiceFactoryBean.initializeServiceModel(ReflectionServiceFactoryBean.java:550)
at org.apache.cxf.service.factory.ReflectionServiceFactoryBean.create(ReflectionServiceFactoryBean.java:265)
at org.apache.cxf.jaxws.support.JaxWsServiceFactoryBean.create(JaxWsServiceFactoryBean.java:215)
at org.apache.cxf.frontend.AbstractWSDLBasedEndpointFactory.createEndpoint(AbstractWSDLBasedEndpointFactory.java:102)
at org.apache.cxf.frontend.ServerFactoryBean.create(ServerFactoryBean.java:159)
at org.apache.cxf.jaxws.JaxWsServerFactoryBean.create(JaxWsServerFactoryBean.java:211)
at org.apache.cxf.jaxws.EndpointImpl.getServer(EndpointImpl.java:456)
at org.apache.cxf.jaxws.EndpointImpl.doPublish(EndpointImpl.java:334)
... 30 more
Caused by: com.sun.xml.internal.bind.v2.runtime.IllegalAnnotationsException: 1 counts of IllegalAnnotationExceptions
Class has two properties of the same name ""tSort""
this problem is related to the following location:
at public int com.edulife.model.merit.Dept.gettSort()
at com.edulife.model.merit.Dept
at public com.edulife.model.merit.Dept com.edulife.model.security.User.getDept()
at com.edulife.model.security.User
at private com.edulife.model.security.User com.edulife.ws.service.jaxws_asm.QuerySchoolNews.arg4
at com.edulife.ws.service.jaxws_asm.QuerySchoolNews
this problem is related to the following location:
at public int com.edulife.model.merit.Dept.tSort
at com.edulife.model.merit.Dept
at public com.edulife.model.merit.Dept com.edulife.model.security.User.getDept()
at com.edulife.model.security.User
at private com.edulife.model.security.User com.edulife.ws.service.jaxws_asm.QuerySchoolNews.arg4
at com.edulife.ws.service.jaxws_asm.QuerySchoolNews

at com.sun.xml.internal.bind.v2.runtime.IllegalAnnotationsException$Builder.check(Unknown Source)at com.sun.xml.internal.bind.v2.runtime.JAXBContextImpl.getTypeInfoSet(Unknown Source)at com.sun.xml.internal.bind.v2.runtime.JAXBContextImpl.<init>(Unknown Source)at com.sun.xml.internal.bind.v2.runtime.JAXBContextImpl.<init>(Unknown Source)at com.sun.xml.internal.bind.v2.runtime.JAXBContextImpl$JAXBContextBuilder.build(Unknown Source)at com.sun.xml.internal.bind.v2.ContextFactory.createContext(Unknown Source)at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)at java.lang.reflect.Method.invoke(Unknown Source)at javax.xml.bind.ContextFinder.newInstance(Unknown Source)at javax.xml.bind.ContextFinder.newInstance(Unknown Source)at javax.xml.bind.ContextFinder.find(Unknown Source)at javax.xml.bind.JAXBContext.newInstance(Unknown Source)at org.apache.cxf.common.jaxb.JAXBContextCache.createContext(JAXBContextCache.java:356)at org.apache.cxf.common.jaxb.JAXBContextCache.getCachedContextAndSchemas(JAXBContextCache.java:244)at org.apache.cxf.jaxb.JAXBDataBinding.createJAXBContextAndSchemas(JAXBDataBinding.java:484)at org.apache.cxf.jaxb.JAXBDataBinding.initialize(JAXBDataBinding.java:339)... 41 more

解决方案

不是你那句话的问题,报这种错的一般是配置文件的问题,再检查下配置文件

时间: 2016-09-13

cxf-CXF WebService发布报错,各位大神请看下的相关文章

weblogic11程序部署报错,大神帮忙看下

问题描述 weblogic11程序部署报错,大神帮忙看下 安装时报错,错误如下: - 错误 激活更改期间出错, 有关详细信息, 请查看日志. - 错误 weblogic.application.ModuleException: - 错误 com.icitic.hrms.doc.ucc.impl.DocBrowseUCCImpl - 成功 已成功安装布署. 状态显示为失败. 解决方案 你这个信息量太少太少了,,,

EaseUI3.0集成报错 求大神帮忙看下

问题描述 解决方案 在报错的文件中导入头文件#import "EMClient.h"#import "EMClientDelegate.h"

javase-Java连接derby报错,求大神帮解决下~

问题描述 Java连接derby报错,求大神帮解决下~ 解决方案 http://tieba.baidu.com/p/1415330675 用SYS登录时不可以进行建表操作,看样子derby的确有权限控制存在.哼哼哼哼--- 另,用户名中不能存在字符,刚才在用户名中包含了一个;号,结果出现了 错误 58009:网络协议异常:在 DSS 链中的下一个 DSS 段与当前段具有相同的标识号.连接已终止.错误 08004:发生连接认证失败.原因:用户无权访问数据库. 这样的错误 解决方案二: http:/

CXF WebService发布报错,各位大神请看下

问题描述 只要在maven项目上加了下面这段代码发布webservice就报错(我自己写的demo是正常的)<beanid="schoolNewsBean"class="com.edulife.ws.impl.SchoolNewsImpl"></bean><!--要发布成webservice的bean--><jaxws:endpointimplementor="#schoolNewsBean"addres

vs2012安装报错,大神请指教

问题描述 装vs2012报错,百度后一直没找到正确方法,求大神指教,解决后再次加分以示感谢. 解决方案 解决方案二:管理员身份运行

iOS集成parse的报错,大神请进

问题描述 我把 SDK3.xDemo中的Parse.framework Bolts.framework UserProfileManager.h UserProfileManager.m拖进我的工程后,报了6个错: 解决方案 应该是缺少这两个依赖Accounts.frameworkSocial.framework解决方案二:顶一个,不要沉

集成环信SDK报错 求大神帮忙看一下

问题描述 解决方案 如果需要语音功能,将lib文件夹中libEaseMobClientSDKlite.a包删除,使用libEaseMobClientSDK.a,other linker flags使用-ObjC,不要加.a文件地址.解决方案二:other linker那里截图解决方案三:求帮忙看下为什么.......

Genymoation安装之后打开虚拟机报错求大神指点

问题描述 Genymoation安装之后打开虚拟机报错求大神指点 错误是这样的 求大神指点,谢谢 解决方案 多启动几次,如果还不行,就启动virtualbox,在里面看看对应的虚拟机是否正常可以启动,或者先关掉它

软件开发-JAVA在下载的时候报错,各位大神路过顺便帮忙看下吧

问题描述 JAVA在下载的时候报错,各位大神路过顺便帮忙看下吧 ClientAbortException: java.io.IOException at org.apache.catalina.connector.OutputBuffer.realWriteBytes(OutputBuffer.java:369) at org.apache.tomcat.util.buf.ByteChunk.append(ByteChunk.java:368) at org.apache.catalina.co