0

I have Maven project and I am using (wildfly-8.1.0.Final), in addition to use (jdk1.7.0_67). After getting my project WAR I try to run the server but always I have the following:

16:04:51,518 INFO  [org.apache.cxf.service.factory.ReflectionServiceFactoryBean] (MSC service thread 1-4) Creating Service {http://www.jboss.org/jbossas/quickstarts/wshelloworld/HelloWorld}HelloWorldService from class org.jboss.as.quickstarts.wshelloworld.HelloWorldService
16:04:51,566 ERROR [org.jboss.msc.service.fail] (MSC service thread 1-4) MSC000001: Failed to start service jboss.deployment.unit."helloWorld.war".INSTALL: org.jboss.msc.service.StartException in service jboss.deployment.unit."helloWorld.war".INSTALL: JBAS018733: Failed to process phase INSTALL of deployment "helloWorld.war"
        at org.jboss.as.server.deployment.DeploymentUnitPhaseService.start(DeploymentUnitPhaseService.java:166) [wildfly-server-8.1.0.Final.jar:8.1.0.Final]
        at org.jboss.msc.service.ServiceControllerImpl$StartTask.startService(ServiceControllerImpl.java:1948) [jboss-msc-1.2.2.Final.jar:1.2.2.Final]
        at org.jboss.msc.service.ServiceControllerImpl$StartTask.run(ServiceControllerImpl.java:1881) [jboss-msc-1.2.2.Final.jar:1.2.2.Final]
        at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145) [rt.jar:1.7.0_67]
        at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615) [rt.jar:1.7.0_67]
        at java.lang.Thread.run(Thread.java:745) [rt.jar:1.7.0_67]
Caused by: java.lang.UnsupportedClassVersionError: org/jboss/as/quickstarts/wshelloworld/jaxws_asm/package-info : Unsupported major.minor version 0.0
        at java.lang.ClassLoader.defineClass1(Native Method) [rt.jar:1.7.0_67]
        at java.lang.ClassLoader.defineClass(ClassLoader.java:800) [rt.jar:1.7.0_67]
        at java.lang.ClassLoader.defineClass(ClassLoader.java:643) [rt.jar:1.7.0_67]
        at org.apache.cxf.common.util.ASMHelper$TypeHelperClassLoader.defineClass(ASMHelper.java:367)
        at org.apache.cxf.common.util.ASMHelper.loadClass(ASMHelper.java:316)
        at org.apache.cxf.jaxws.WrapperClassGenerator.generatePackageInfo(WrapperClassGenerator.java:267)
        at org.apache.cxf.jaxws.WrapperClassGenerator.createWrapperClass(WrapperClassGenerator.java:169)
        at org.apache.cxf.jaxws.WrapperClassGenerator.generate(WrapperClassGenerator.java:122)
        at org.apache.cxf.jaxws.support.JaxWsServiceFactoryBean.generatedWrapperBeanClass(JaxWsServiceFactoryBean.java:683)
        at org.apache.cxf.jaxws.support.JaxWsServiceFactoryBean.getExtraClass(JaxWsServiceFactoryBean.java:653)
        at org.apache.cxf.service.factory.ReflectionServiceFactoryBean.buildServiceFromClass(ReflectionServiceFactoryBean.java:484)
        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)
        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:117)
        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:75)
        at org.jboss.as.server.deployment.DeploymentUnitPhaseService.start(DeploymentUnitPhaseService.java:159) [wildfly-server-8.1.0.Final.jar:8.1.0.Final]
        ... 5 more

Any help?!

user2034269
  • 109
  • 1
  • 3
  • 13
  • What is in that package-info file? How do you build your project as this could be build issue with wrongly producing package-info. Is this standard quickstart for wildfly? As i cannot find this package in official helloworld-ws quickstart... – Tomaz Cerar Sep 05 '14 at 14:01

2 Answers2

0

I have manged to solve the problem. In my pom.xml I just replaced this dependency

<dependency>
     <groupId>org.apache.cxf</groupId>
     <artifactId>cxf-bundle</artifactId>
     <version>2.2.9</version>
</dependency>

with this

<dependency>
    <groupId>org.apache.cxf</groupId>
    <artifactId>cxf-bundle-jaxrs</artifactId>
    <version>2.7.0</version>
</dependency>
user2034269
  • 109
  • 1
  • 3
  • 13
0

I had the same problem and it was that wildfly comes with its own asm libraries, so if your code have any dependencies that depends on asm, your deployment is packaging asm.jar in your ear/jar and when you deploy them in wildfly ... clash and problems.

If you need to include the dependency that depends on asm, simply include it but exclude asm like:

<dependency>
    <groupId>org.codehaus.groovy</groupId>
    <artifactId>groovy</artifactId>
    <version>${groovy.version}</version>
    <exclusions>
        <exclusion>
            <artifactId>asm</artifactId>
            <groupId>asm</groupId>
        </exclusion>
        <exclusion>
            <artifactId>asm-util</artifactId>
            <groupId>asm</groupId>
        </exclusion>
        <exclusion>
            <artifactId>asm-analysis</artifactId>
            <groupId>asm</groupId>
        </exclusion>
        <exclusion>
            <artifactId>asm-tree</artifactId>
            <groupId>asm</groupId>
        </exclusion>
    </exclusions>
</dependency>

That was my problem, I was using in my utilities module the groovy dependency and my utilities.jar in my EJB, so when I call the EJB (a Webservice consumer) that was deployed in wildfly10 ... Boooom I got the error of the headline.

After excluding asm dependencies, everything was working flawless.

NOTE: use "mvn dependency:tree" for seeking the package containing the asm as dependency

periket2000
  • 543
  • 7
  • 13