0 Replies Latest reply on Apr 8, 2014 9:59 AM by hemant sharma

    Issues in deployment while using aspect + activeMQ on Fuse esb 6.0

    hemant sharma Newbie

      Hi, I am facing issues in deployment while using aspect in my application. I am getting an exception :

      org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'activeMQ' defined in URL bundle://149.0:0/META-INF/spring/esb-audit-common-context.xml: Initialization of bean failed; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'camel-1': Invocation of init method failed; nested exception is java.lang.IllegalStateException: Expecting raw type, not: org.apache.camel.core.xml.AbstractCamelContextFactoryBean

           at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:527)[167:org.springframework.beans:3.1.3.RELEASE]

           at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:456)[167:org.springframework.beans:3.1.3.RELEASE]

           at org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:294)[167:org.springframework.beans:3.1.3.RELEASE]

           at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:225)[167:org.springframework.beans:3.1.3.RELEASE]

           at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:291)[167:org.springframework.beans:3.1.3.RELEASE]

           at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:193)[167:org.springframework.beans:3.1.3.RELEASE]

           at org.springframework.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingletons(DefaultListableBeanFactory.java:605)[167:org.springframework.beans:3.1.3.RELEASE]

           at org.springframework.context.support.AbstractApplicationContext.finishBeanFactoryInitialization(AbstractApplicationContext.java:925)[181:org.springframework.context:3.1.3.RELEASE]

           at org.springframework.osgi.context.support.AbstractDelegatedExecutionApplicationContext.access$1600(AbstractDelegatedExecutionApplicationContext.java:69)[107:org.springframework.osgi.core:1.2.1]

           at org.springframework.osgi.context.support.AbstractDelegatedExecutionApplicationContext$4.run(AbstractDelegatedExecutionApplicationContext.java:355)[107:org.springframework.osgi.core:1.2.1]

           at org.springframework.osgi.util.internal.PrivilegedUtils.executeWithCustomTCCL(PrivilegedUtils.java:85)[107:org.springframework.osgi.core:1.2.1]

           at org.springframework.osgi.context.support.AbstractDelegatedExecutionApplicationContext.completeRefresh(AbstractDelegatedExecutionApplicationContext.java:320)[107:org.springframework.osgi.core:1.2.1]

           at org.springframework.osgi.extender.internal.dependencies.startup.DependencyWaiterApplicationContextExecutor$CompleteRefreshTask.run(DependencyWaiterApplicationContextExecutor.java:132)[138:org.springframework.osgi.extender:1.2.1]

           at java.lang.Thread.run(Thread.java:744)[:1.7.0_45]

      Caused by: org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'camel-1': Invocation of init method failed; nested exception is java.lang.IllegalStateException: Expecting raw type, not: org.apache.camel.core.xml.AbstractCamelContextFactoryBean

           at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1455)[167:org.springframework.beans:3.1.3.RELEASE]

           at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:519)[167:org.springframework.beans:3.1.3.RELEASE]

           at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:456)[167:org.springframework.beans:3.1.3.RELEASE]

           at org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:294)[167:org.springframework.beans:3.1.3.RELEASE]

           at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:225)[167:org.springframework.beans:3.1.3.RELEASE]

           at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:291)[167:org.springframework.beans:3.1.3.RELEASE]

           at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:197)[167:org.springframework.beans:3.1.3.RELEASE]

           at org.springframework.context.support.AbstractApplicationContext.getBean(AbstractApplicationContext.java:1109)[181:org.springframework.context:3.1.3.RELEASE]

           at org.apache.camel.spring.CamelBeanPostProcessor$1.getOrLookupCamelContext(CamelBeanPostProcessor.java:69)[156:org.apache.camel.camel-spring:2.10.0.redhat-60024]

           at org.apache.camel.impl.DefaultCamelBeanPostProcessor.postProcessBeforeInitialization(DefaultCamelBeanPostProcessor.java:85)[125:org.apache.camel.camel-core:2.10.0.redhat-60024]

           at org.apache.camel.spring.CamelBeanPostProcessor.postProcessBeforeInitialization(CamelBeanPostProcessor.java:148)[156:org.apache.camel.camel-spring:2.10.0.redhat-60024]

           at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.applyBeanPostProcessorsBeforeInitialization(AbstractAutowireCapableBeanFactory.java:394)[167:org.springframework.beans:3.1.3.RELEASE]

           at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1448)[167:org.springframework.beans:3.1.3.RELEASE]

           at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:519)[167:org.springframework.beans:3.1.3.RELEASE]

           ... 13 more

      Caused by: java.lang.IllegalStateException: Expecting raw type, not: org.apache.camel.core.xml.AbstractCamelContextFactoryBean

           at org.aspectj.weaver.TypeFactory.createParameterizedType(TypeFactory.java:34)[114:com.springsource.org.aspectj.weaver:1.7.2.RELEASE]

           at org.aspectj.weaver.reflect.JavaLangTypeToResolvedTypeConverter.fromType(JavaLangTypeToResolvedTypeConverter.java:79)[114:com.springsource.org.aspectj.weaver:1.7.2.RELEASE]

           at org.aspectj.weaver.reflect.Java15ReflectionBasedReferenceTypeDelegate.getSuperclass(Java15ReflectionBasedReferenceTypeDelegate

       

      -


      This is activeMQ bean is in one of my Jms spring context file:

       

      -


      here is my advice:

      @AfterThrowing(pointcut = "execution(* com.myorg.esb...(..)) and !within(org.apache..*)", throwing = "error")

          public void serviceErrorResponse(JoinPoint joinPoint, SpeedwingBaseException error)

       

      -


      here is my aop context file:

       

      -


      Any help would be highly appreciated.