4 Replies Latest reply on Mar 1, 2012 11:43 AM by baleado

    Camel CXF

    baleado Newbie

      Hi,

       

      I'm trying to create a bundle with a camel route to export a web service.

       

      When I try to deploy my bundle in Fuse ESB I'm getting the follow error:

       

      "Failed to import bean definitions from URL location classpath:META-INF/spring/camel-cxf.xml"

       

      Here is my camel-cxf.xml:

            

       

      What I'm missing?

        • 1. Re: Camel CXF
          Freeman(Yue) Fang Master

          Hi,

           

          If  file

          classpath:META-INF/spring/camel-cxf.xml"

          is just the camel-cxf.xml you posted here, you shouldn't itself again.

           

          Freeman

          • 2. Re: Camel CXF
            Willem Jiang Master

            Did you have chance to install the camel-cxf feature or camel-cxf-transprot bundle ?

            • 3. Re: Camel CXF
              baleado Newbie

              camel-cxf and camel-cxf-transport are Active.

               

              Now I'm stuck in the follow error:

               

              10:03:57,593 | WARN  | ExtenderThread-6 | OsgiBundleXmlApplicationContext  | 75 - org.springframework.context - 3.0.5.RELEASE | Exception thrown from ApplicationListener handling ContextClosedEvent

              org.springframework.beans.factory.BeanCreationNotAllowedException: Error creating bean with name 'cxf': Singleton bean creation not allowed while the singletons of this factory are in destruction (Do not request a bean from a BeanFactory in a destroy method implementation!)

                   at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:209)[73:org.springframework.beans:3.0.5.RELEASE]

               

              ...

               

              10:03:57,598 | WARN  | ExtenderThread-6 | OsgiBundleXmlApplicationContext  | 75 - org.springframework.context - 3.0.5.RELEASE | Exception thrown from LifecycleProcessor on context close

              java.lang.IllegalStateException: LifecycleProcessor not initialized - call 'refresh' before invoking lifecycle methods via the context: OsgiBundleXmlApplicationContext(bundle=teste, config=osgibundle:/META-INF/spring/*.xml): startup date ; root of context hierarchy

                   at org.springframework.context.support.AbstractApplicationContext.getLifecycleProcessor(AbstractApplicationContext.java:329)

                   at org.springframework.context.support.AbstractApplicationContext.doClose(AbstractApplicationContext.java:1015)

               

              ...

               

              10:03:57,602 | ERROR | ExtenderThread-6 | ContextLoaderListener            | 84 - org.springframework.osgi.extender - 1.2.1 | Application context refresh failed (OsgiBundleXmlApplicationContext(bundle=teste, config=osgibundle:/META-INF/spring/*.xml))

              org.springframework.beans.factory.CannotLoadBeanClassException: Cannot find class for bean with name 'org.apache.cxf.binding.soap.customEditorConfigurer' defined in OSGi resource[classpath:META-INF/cxf/cxf-extension-soap.xml|bnd.id=222|bnd.sym=teste]; nested exception is java.lang.ClassNotFoundException: org.springframework.beans.factory.config.CustomEditorConfigurer not found from bundle

                   at org.springframework.beans.factory.support.AbstractBeanFactory.resolveBeanClass(AbstractBeanFactory.java:1250)[73:org.springframework.beans:3.0.5.RELEASE]

               

              ...

               

              What could be?

              • 4. Re: Camel CXF
                baleado Newbie

                Was missing the org.springframework.beans.factory.config in Import-Package.

                 

                Thanks guys.