3 Replies Latest reply on Mar 20, 2015 5:56 PM by J at

    Can't install rest quickstarts in  jboss-fuse-6.1.0-2

    nmay Newbie

      Hi,

      I follow instructions in the quckstarts directory jboss-fuse-6.1.0-2.redhat-379/quickstarts/rest

       

      after running command:

       

      features:install quickstart-rest
      

       

      got a error message in the fuse.log:

       

      Caused by: java.lang.NoClassDefFoundError: com/wordnik/swagger/jaxrs/listing/ApiListingResourceJSON

              at org.apache.cxf.jaxrs.swagger.SwaggerFeature.initialize(SwaggerFeature.java:48)

              at org.apache.cxf.jaxrs.JAXRSServerFactoryBean.applyFeatures(JAXRSServerFactoryBean.java:231)

              at org.apache.cxf.jaxrs.JAXRSServerFactoryBean.create(JAXRSServerFactoryBean.java:186)

              at org.apache.cxf.jaxrs.JAXRSServerFactoryBean.init(JAXRSServerFactoryBean.java:135)

       

      Can't figure out  how to bring it to run ... Do I need to install swagger feature ? How to do it ?

       

      Regards,

      Niko

        • 1. Re: Can't install rest quickstarts in  jboss-fuse-6.1.0-2
          Freeman(Yue) Fang Master

          Hi,

           

          The quickstart-rest feature already contain the swagger feature,

          features:info quickstart-rest

          Description of quickstart-rest 6.1.0.redhat-379 feature

          ----------------------------------------------------------------

          Feature has no configuration

          Feature has no configuration files

          Feature depends on:

            swagger 1.0.0.redhat-379

            cxf-jaxrs [2.7,3)

          Feature contains followed bundles:

          mvn:org.jboss.quickstarts.fuse/rest/6.1.0.redhat-379

           

          And I just did a quick test of this quickstart, it works for me. Did you exactly follow the instruction in README.txt?

           

          Freeman

          1 of 1 people found this helpful
          • 2. Re: Can't install rest quickstarts in  jboss-fuse-6.1.0-2
            nmay Newbie

            Hi,

            Probably something goes wrong then did mvn install .  I remove data directory restart fuse and install bundle again. After it works !

            Thanks for hit!

            • 3. Re: Can't install rest quickstarts in  jboss-fuse-6.1.0-2
              J at Newbie

              Hi I have a similar problem with the examples in quickstart, specifically for rest and secure-rest

              mvn step runs successfully, now when I try to execute the commands from fuse console for the res example, it doesn't give me any id and in the logs I get this error :

               

               

              015-03-20 10:59:55,968 | ERROR | l Console Thread | BlueprintContainerImpl  | ?? | 9 - org.apache.aries.blueprint.core - 1.0.1.redhat-610379 | Unable to

              start blueprint container for bundle org.jboss.quickstarts.fuse.rest

              org.osgi.service.blueprint.container.ComponentDefinitionException: Unable to initialize bean customerService

                     at org.apache.aries.blueprint.container.BeanRecipe.runBeanProcInit(BeanRecipe.java:714)[9:org.apache.aries.blueprint.core:1.0.1.redhat-610379]

                     at org.apache.aries.blueprint.container.BeanRecipe.internalCreate2(BeanRecipe.java:824)[9:org.apache.aries.blueprint.core:1.0.1.redhat-610379]

                     at org.apache.aries.blueprint.container.BeanRecipe.internalCreate(BeanRecipe.java:787)[9:org.apache.aries.blueprint.core:1.0.1.redhat-610379]

                     at org.apache.aries.blueprint.di.AbstractRecipe$1.call(AbstractRecipe.java:79)[9:org.apache.aries.blueprint.core:1.0.1.redhat-610379]

                     at java.util.concurrent.FutureTask.run(FutureTask.java:262)[:1.7.0_75]

                     at org.apache.aries.blueprint.di.AbstractRecipe.create(AbstractRecipe.java:88)[9:org.apache.aries.blueprint.core:1.0.1.redhat-610379]

                     at org.apache.aries.blueprint.container.BlueprintRepository.createInstances(BlueprintRepository.java:245)[9:org.apache.aries.blueprint.core:1.0.1.redhat-610379]

                     at org.apache.aries.blueprint.container.BlueprintRepository.createAll(BlueprintRepository.java:183)[9:org.apache.aries.blueprint.core:1.0.1.redhat-610379]

                     at org.apache.aries.blueprint.container.BlueprintContainerImpl.instantiateEagerComponents(BlueprintContainerImpl.java:676)[9:org.apache.aries.blueprint.core:1.0.1.redhat-610379]

                     at org.apache.aries.blueprint.container.BlueprintContainerImpl.doRun(BlueprintContainerImpl.java:374)[9:org.apache.aries.blueprint.core:1.0.1.redhat-610379]

                     at org.apache.aries.blueprint.container.BlueprintContainerImpl.run(BlueprintContainerImpl.java:261)[9:org.apache.aries.blueprint.core:1.0.1.redhat-610379]

                     at org.apache.aries.blueprint.container.BlueprintExtender.createContainer(BlueprintExtender.java:270)[9:org.apache.aries.blueprint.core:1.0.1.redhat-610379]

                     at org.apache.aries.blueprint.container.BlueprintExtender.modifiedBundle(BlueprintExtender.java:233)[9:org.apache.aries.blueprint.core:1.0.1.redhat-610379]

                     at org.apache.aries.util.tracker.hook.BundleHookBundleTracker$Tracked.customizerModified(BundleHookBundleTracker.java:500)[11:org.apache.aries.util:1.0.1.redhat-610379]

                     at org.apache.aries.util.tracker.hook.BundleHookBundleTracker$Tracked.customizerModified(BundleHookBundleTracker.java:433)[11:org.apache.aries.util:1.0.1.redhat-610379]

                     at org.apache.aries.util.tracker.hook.BundleHookBundleTracker$AbstractTracked.track(BundleHookBundleTracker.java:725)[11:org.apache.aries.util:1.0.1.redhat-610379]

                     at org.apache.aries.util.tracker.hook.BundleHookBundleTracker$Tracked.bundleChanged(BundleHookBundleTracker.java:463)[11:org.apache.aries.util:1.0.1.redhat-610379]

                     at org.apache.aries.util.tracker.hook.BundleHookBundleTracker$BundleEventHook.event(BundleHookBundleTracker.java:422)[11:org.apache.aries.util:1.0.1.redhat-610379]

                     at org.apache.felix.framework.util.SecureAction.invokeBundleEventHook(SecureAction.java:1103)[org.apache.felix.framework-4.0.3.redhat-610379.jar:]

                     at org.apache.felix.framework.util.EventDispatcher.createWhitelistFromHooks(EventDispatcher.java:696)[org.apache.felix.framework-4.0.3.redhat-610379.jar:]

                     at org.apache.felix.framework.util.EventDispatcher.fireBundleEvent(EventDispatcher.java:484)[org.apache.felix.framework-4.0.3.redhat-610379.jar:]

                     at org.apache.felix.framework.Felix.fireBundleEvent(Felix.java:4650)[org.apache.felix.framework-4.0.3.redhat-610379.jar:]

                     at org.apache.felix.framework.Felix$4.run(Felix.java:2123)[org.apache.felix.framework-4.0.3.redhat-610379.jar:]

                     at org.apache.felix.framework.Felix.runInContext(Felix.java:2147)[org.apache.felix.framework-4.0.3.redhat-610379.jar:]

                     at org.apache.felix.framework.Felix.startBundle(Felix.java:2121)[org.apache.felix.framework-4.0.3.redhat-610379.jar:]

                     at org.apache.felix.framework.BundleImpl.start(BundleImpl.java:955)[org.apache.felix.framework-4.0.3.redhat-610379.jar:]

                     at org.apache.felix.framework.BundleImpl.start(BundleImpl.java:942)[org.apache.felix.framework-4.0.3.redhat-610379.jar:]

                     at org.apache.karaf.features.internal.FeaturesServiceImpl.installFeatures(FeaturesServiceImpl.java:474)[22:org.apache.karaf.features.core:2.3.0.redhat-610379]

                     at org.apache.karaf.features.internal.FeaturesServiceImpl.installFeature(FeaturesServiceImpl.java:404)[22:org.apache.karaf.features.core:2.3.0.redhat-610379]

                     at org.apache.karaf.features.internal.FeaturesServiceImpl.installFeature(FeaturesServiceImpl.java:400)[22:org.apache.karaf.features.core:2.3.0.redhat-610379]

                     at org.apache.karaf.features.command.InstallFeatureCommand.doExecute(InstallFeatureCommand.java:62)[26:org.apache.karaf.features.command:2.3.0.redhat-610379]

                     at org.apache.karaf.features.command.FeaturesCommandSupport.doExecute(FeaturesCommandSupport.java:41)[26:org.apache.karaf.features.command:2.3.0.redhat-610379]

                     at org.apache.karaf.shell.console.OsgiCommandSupport.execute(OsgiCommandSupport.java:39)[17:org.apache.karaf.shell.console:2.3.0.redhat-610379]

                     at org.apache.felix.gogo.commands.basic.AbstractCommand.execute(AbstractCommand.java:35)[17:org.apache.karaf.shell.console:2.3.0.redhat-610379]

                     at org.apache.felix.gogo.runtime.CommandProxy.execute(CommandProxy.java:78)[15:org.apache.felix.gogo.runtime:0.11.0.redhat-610379]

                     at org.apache.felix.gogo.runtime.Closure.executeCmd(Closure.java:477)[15:org.apache.felix.gogo.runtime:0.11.0.redhat-610379]

                     at org.apache.felix.gogo.runtime.Closure.executeStatement(Closure.java:403)[15:org.apache.felix.gogo.runtime:0.11.0.redhat-610379]

                     at org.apache.felix.gogo.runtime.Pipe.run(Pipe.java:108)[15:org.apache.felix.gogo.runtime:0.11.0.redhat-610379]

                     at org.apache.felix.gogo.runtime.Closure.execute(Closure.java:183)[15:org.apache.felix.gogo.runtime:0.11.0.redhat-610379]

                     at org.apache.felix.gogo.runtime.Closure.execute(Closure.java:120)[15:org.apache.felix.gogo.runtime:0.11.0.redhat-610379]

                     at org.apache.felix.gogo.runtime.CommandSessionImpl.execute(CommandSessionImpl.java:89)[15:org.apache.felix.gogo.runtime:0.11.0.redhat-610379]

                     at org.apache.karaf.shell.console.jline.Console.run(Console.java:189)[17:org.apache.karaf.shell.console:2.3.0.redhat-610379]

                     at org.apache.karaf.shell.console.jline.DelayedStarted.run(DelayedStarted.java:61)[17:org.apache.karaf.shell.console:2.3.0.redhat-610379]

              aused by: java.lang.NoClassDefFoundError: Could not initialize class org.apache.cxf.jaxrs.provider.ProviderFactory

                     at org.apache.cxf.jaxrs.AbstractJAXRSFactoryBean.setupFactory(AbstractJAXRSFactoryBean.java:327)

                     at org.apache.cxf.jaxrs.JAXRSServerFactoryBean.create(JAXRSServerFactoryBean.java:171)

                     at org.apache.cxf.jaxrs.JAXRSServerFactoryBean.init(JAXRSServerFactoryBean.java:135)

                     at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)[:1.7.0_75]

                     at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)[:1.7.0_75]

                     at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)[:1.7.0_75]

                     at java.lang.reflect.Method.invoke(Method.java:606)[:1.7.0_75]

                     at org.apache.aries.blueprint.utils.ReflectionUtils.invoke(ReflectionUtils.java:297)

                     at org.apache.aries.blueprint.container.BeanRecipe.invoke(BeanRecipe.java:958)

                     at org.apache.aries.blueprint.container.BeanRecipe.runBeanProcInit(BeanRecipe.java:712)

                     ... 42 more

              I read in a post that this was fixed for 6.2 release but again wasn't this already resolve here [ENTESB-933] Rest and Secure-rest examples fail to install with javax.ws.rs.NotFoundException - JBoss Issue Tracker

               

              Thanks