@H_404_1@我正在使用
Java WS从Jboss 5.1.0迁移到Jboss 6.3.0 EAP的应用程序.它适用于Jboss 5.1.0但在Jboss 6.3.0 EAP中部署相同时遇到错误.
14:42:10,887 ERROR [org.jboss.msc.service.fail] (MSC service thread 1-2) MSC000001: Failed to start service jboss.deploy ment.unit."my-app.war".INSTALL: org.jboss.msc.service.StartException in service jboss.deployment.unit."dtm-banking. war".INSTALL: JBAS018733: Failed to process phase INSTALL of deployment "dtm-banking.war" at org.jboss.as.server.deployment.DeploymentUnitPhaseService.start(DeploymentUnitPhaseService.java:166) [jboss-a s-server-7.4.0.Final-redhat-19.jar:7.4.0.Final-redhat-19] at org.jboss.msc.service.ServiceControllerImpl$StartTask.startService(ServiceControllerImpl.java:1980) [jboss-ms c-1.1.5.Final-redhat-1.jar:1.1.5.Final-redhat-1] at org.jboss.msc.service.ServiceControllerImpl$StartTask.run(ServiceControllerImpl.java:1913) [jboss-msc-1.1.5.F inal-redhat-1.jar:1.1.5.Final-redhat-1] at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145) [rt.jar:1.7.0_60] at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615) [rt.jar:1.7.0_60] at java.lang.Thread.run(Thread.java:745) [rt.jar:1.7.0_60] Caused by: javax.xml.ws.WebServiceException: java.lang.reflect.UndeclaredThrowableException at org.apache.cxf.jaxws.EndpointImpl.doPublish(EndpointImpl.java:371) at org.jboss.wsf.stack.cxf.deployment.EndpointImpl.doPublish(EndpointImpl.java:66) at org.apache.cxf.jaxws.EndpointImpl.publish(EndpointImpl.java:251) at org.apache.cxf.jaxws.EndpointImpl.publish(EndpointImpl.java:539) at org.jboss.wsf.stack.cxf.configuration.NonSpringBusHolder.configure(NonSpringBusHolder.java:118) at org.jboss.wsf.stack.cxf.deployment.aspect.BusDeploymentAspect.startDeploymentBus(BusDeploymentAspect.java:137 ) at org.jboss.wsf.stack.cxf.deployment.aspect.BusDeploymentAspect.start(BusDeploymentAspect.java:69) at org.jboss.as.webservices.deployers.AspectDeploymentProcessor.deploy(AspectDeploymentProcessor.java:74) at org.jboss.as.server.deployment.DeploymentUnitPhaseService.start(DeploymentUnitPhaseService.java:159) [jboss-a s-server-7.4.0.Final-redhat-19.jar:7.4.0.Final-redhat-19] ... 5 more Caused by: java.lang.reflect.UndeclaredThrowableException at com.sun.proxy.$Proxy371.visitLabel(Unknown Source) at org.apache.cxf.jaxws.WrapperClassGenerator.createWrapperClass(WrapperClassGenerator.java:213) at org.apache.cxf.jaxws.WrapperClassGenerator.generate(WrapperClassGenerator.java:122) at org.apache.cxf.jaxws.support.JaxWsServicefactorybean.generatedWrapperBeanClass(JaxWsServicefactorybean.java:6 83) at org.apache.cxf.jaxws.support.JaxWsServicefactorybean.getExtraClass(JaxWsServicefactorybean.java:653) at org.apache.cxf.service.factory.ReflectionServicefactorybean.buildServiceFromClass(ReflectionServiceFactoryBea n.java:484) at org.apache.cxf.jaxws.support.JaxWsServicefactorybean.buildServiceFromClass(JaxWsServicefactorybean.java:704) at org.apache.cxf.service.factory.ReflectionServicefactorybean.initializeServiceModel(ReflectionServiceFactoryBe an.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) ... 13 more Caused by: java.lang.NoSuchMethodException: org.objectweb.asm.MethodWriter.visitLabel(org.objectweb.asm.Label) at java.lang.Class.getMethod(Class.java:1665) [rt.jar:1.7.0_60] at org.apache.cxf.common.util.ReflectionInvokationHandler.invoke(ReflectionInvokationHandler.java:85) ... 28 more
我理解Jboss 6.3.0 EAP使用CXF实现webservice,但我正在寻找简单的Java WS来使用标准的Java EE环境.@H_403_5@
在jboss-deployment-structure.xml中尝试了以下内容@H_403_5@
<exclude-subsystems> <subsystem name="webservices" /> </exclude-subsystems>
这在部署时摆脱了异常,但在调用服务的wsdl时我得到了一个Classcast异常@H_403_5@
http://localhost:8080/myapp/myservice?wsdl@H_403_5@
JBWEB000235:为servlet MyWebService分配异常:java.lang.ClassCastException:com.example.webservice.endpoint.DataService无法强制转换为javax.servlet.Servlet@H_403_5@
任何的想法?@H_403_5@