org.springframework.beans.factory.BeanIsAbstractException: Tried to instantiate abstract bean definition '&baseTransactionProxy'

Spring JIRA | Patrick Burleson | 1 decade ago
  1. 0

    Using the cool new Abstract bean definition for defining common transaction attributes seems to cause a problem with the VelocityView class. Adapting the config from the petclinic example to my app, only copying over the Transaction stuff to apply to my Hibernate Session Factory. Before I added this, my Velocity config was working fine. Ever since adding this, I get the following error: org.springframework.beans.factory.BeanIsAbstractException: Tried to instantiate abstract bean definition '&baseTransactionProxy' at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:177) at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:136) at org.springframework.beans.factory.support.DefaultListableBeanFactory.getBeansOfType(DefaultListableBeanFactory.java:177) at org.springframework.context.support.AbstractApplicationContext.getBeansOfType(AbstractApplicationContext.java:473) at org.springframework.beans.factory.BeanFactoryUtils.beansOfTypeIncludingAncestors(BeanFactoryUtils.java:108) at org.springframework.beans.factory.BeanFactoryUtils.beansOfTypeIncludingAncestors(BeanFactoryUtils.java:112) at org.springframework.beans.factory.BeanFactoryUtils.beanOfTypeIncludingAncestors(BeanFactoryUtils.java:141) at org.springframework.web.servlet.view.velocity.VelocityView.initApplicationContext(VelocityView.java:182) at org.springframework.context.support.ApplicationObjectSupport.setApplicationContext(ApplicationObjectSupport.java:79) at org.springframework.web.servlet.view.AbstractCachingViewResolver.loadAndConfigureView(AbstractCachingViewResolver.java:123) at org.springframework.web.servlet.view.AbstractCachingViewResolver.resolveViewName(AbstractCachingViewResolver.java:78) at org.springframework.web.servlet.DispatcherServlet.render(DispatcherServlet.java:629) at org.springframework.web.servlet.DispatcherServlet.doService(DispatcherServlet.java:535) at org.springframework.web.servlet.FrameworkServlet.service(FrameworkServlet.java:321) at javax.servlet.http.HttpServlet.service(HttpServlet.java:802) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:237) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:157) at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:214) at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:104) at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520) at org.apache.catalina.core.StandardContextValve.invokeInternal(StandardContextValve.java:198) at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:152) at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:104) at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520) at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:137) at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:104) at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:117) at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:102) at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520) at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109) at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:104) at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520) at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:929) at org.apache.coyote.tomcat5.CoyoteAdapter.service(CoyoteAdapter.java:160) at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:799) at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.processConnection(Http11Protocol.java:705) at org.apache.tomcat.util.net.TcpWorkerThread.runIt(PoolTcpEndpoint.java:577) at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:683) at java.lang.Thread.run(Thread.java:595) The problem seems to be around line 182 of VelocityView.java in org.springframework.web.servlet.view.velocity when it uses BeanFactoryUtils.beanOfTypeIncludingAncestors() . It also appears that this affects the Freemarker implementation as well (just eyeballing the code). If you need them, I can profile my context configuration files.

    Spring JIRA | 1 decade ago | Patrick Burleson
    org.springframework.beans.factory.BeanIsAbstractException: Tried to instantiate abstract bean definition '&baseTransactionProxy'
  2. 0

    Using the cool new Abstract bean definition for defining common transaction attributes seems to cause a problem with the VelocityView class. Adapting the config from the petclinic example to my app, only copying over the Transaction stuff to apply to my Hibernate Session Factory. Before I added this, my Velocity config was working fine. Ever since adding this, I get the following error: org.springframework.beans.factory.BeanIsAbstractException: Tried to instantiate abstract bean definition '&baseTransactionProxy' at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:177) at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:136) at org.springframework.beans.factory.support.DefaultListableBeanFactory.getBeansOfType(DefaultListableBeanFactory.java:177) at org.springframework.context.support.AbstractApplicationContext.getBeansOfType(AbstractApplicationContext.java:473) at org.springframework.beans.factory.BeanFactoryUtils.beansOfTypeIncludingAncestors(BeanFactoryUtils.java:108) at org.springframework.beans.factory.BeanFactoryUtils.beansOfTypeIncludingAncestors(BeanFactoryUtils.java:112) at org.springframework.beans.factory.BeanFactoryUtils.beanOfTypeIncludingAncestors(BeanFactoryUtils.java:141) at org.springframework.web.servlet.view.velocity.VelocityView.initApplicationContext(VelocityView.java:182) at org.springframework.context.support.ApplicationObjectSupport.setApplicationContext(ApplicationObjectSupport.java:79) at org.springframework.web.servlet.view.AbstractCachingViewResolver.loadAndConfigureView(AbstractCachingViewResolver.java:123) at org.springframework.web.servlet.view.AbstractCachingViewResolver.resolveViewName(AbstractCachingViewResolver.java:78) at org.springframework.web.servlet.DispatcherServlet.render(DispatcherServlet.java:629) at org.springframework.web.servlet.DispatcherServlet.doService(DispatcherServlet.java:535) at org.springframework.web.servlet.FrameworkServlet.service(FrameworkServlet.java:321) at javax.servlet.http.HttpServlet.service(HttpServlet.java:802) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:237) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:157) at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:214) at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:104) at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520) at org.apache.catalina.core.StandardContextValve.invokeInternal(StandardContextValve.java:198) at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:152) at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:104) at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520) at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:137) at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:104) at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:117) at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:102) at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520) at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109) at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:104) at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520) at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:929) at org.apache.coyote.tomcat5.CoyoteAdapter.service(CoyoteAdapter.java:160) at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:799) at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.processConnection(Http11Protocol.java:705) at org.apache.tomcat.util.net.TcpWorkerThread.runIt(PoolTcpEndpoint.java:577) at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:683) at java.lang.Thread.run(Thread.java:595) The problem seems to be around line 182 of VelocityView.java in org.springframework.web.servlet.view.velocity when it uses BeanFactoryUtils.beanOfTypeIncludingAncestors() . It also appears that this affects the Freemarker implementation as well (just eyeballing the code). If you need them, I can profile my context configuration files.

    Spring JIRA | 1 decade ago | Patrick Burleson
    org.springframework.beans.factory.BeanIsAbstractException: Tried to instantiate abstract bean definition '&baseTransactionProxy'
  3. 0

    [FCREPO-1194] Rebuilders fail when a Management Delegate bean is configured - DuraSpace JIRA

    duraspace.org | 12 months ago
    org.springframework.beans.factory.BeanIsAbstractException: Error creating bean with name 'org.fcrepo.server.security.Authorization': Bean definition is abstract
  4. Speed up your debug routine!

    Automated exception search integrated into your IDE

  5. 0

    the AbstractAutowireCapableBeanFactory.autowireByName try to autowire abstrat bean , if there is abstrat bean that is matched with a bean proparty the AbstractAutowireCapableBeanFactory will try to wire it even if the bean is abstrat , i think abstrat beans should be excluded from autowireing this will result in org.springframework.beans.factory.BeanIsAbstractException: Error creating bean with name 'service': Bean definition is abstract at org.springframework.beans.factory.support.AbstractBeanFactory.checkMergedBeanDefinition(AbstractBeanFactory.java:1116) at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:228) at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:164) at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.autowireByName(AbstractAutowireCapableBeanFactory.java:959) at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.populateBean(AbstractAutowireCapableBeanFactory.java:907) at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:437) at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory$1.run(AbstractAutowireCapableBeanFactory.java:383) at java.security.AccessController.doPrivileged(Native Method) at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:353)

    Spring JIRA | 9 years ago | Usama Rashwan
    org.springframework.beans.factory.BeanIsAbstractException: Error creating bean with name 'service': Bean definition is abstract
  6. 0

    CAS migrating to new version

    Google Groups | 7 months ago | Sankalp Sharma
    org.springframework.beans.factory.BeanIsAbstractException: Error creating bean with name 'httpClient': Bean definition is abstract

    Not finding the right solution?
    Take a tour to get the most out of Samebug.

    Tired of useless tips?

    Automated exception search integrated into your IDE

    Root Cause Analysis

    1. org.springframework.beans.factory.BeanIsAbstractException

      Tried to instantiate abstract bean definition '&baseTransactionProxy'

      at org.springframework.beans.factory.support.AbstractBeanFactory.getBean()
    2. Spring Beans
      DefaultListableBeanFactory.getBeansOfType
      1. org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:177)
      2. org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:136)
      3. org.springframework.beans.factory.support.DefaultListableBeanFactory.getBeansOfType(DefaultListableBeanFactory.java:177)
      3 frames
    3. Spring Context
      AbstractApplicationContext.getBeansOfType
      1. org.springframework.context.support.AbstractApplicationContext.getBeansOfType(AbstractApplicationContext.java:473)
      1 frame
    4. Spring Beans
      BeanFactoryUtils.beanOfTypeIncludingAncestors
      1. org.springframework.beans.factory.BeanFactoryUtils.beansOfTypeIncludingAncestors(BeanFactoryUtils.java:108)
      2. org.springframework.beans.factory.BeanFactoryUtils.beansOfTypeIncludingAncestors(BeanFactoryUtils.java:112)
      3. org.springframework.beans.factory.BeanFactoryUtils.beanOfTypeIncludingAncestors(BeanFactoryUtils.java:141)
      3 frames
    5. Spring MVC
      VelocityView.initApplicationContext
      1. org.springframework.web.servlet.view.velocity.VelocityView.initApplicationContext(VelocityView.java:182)
      1 frame
    6. Spring Context
      ApplicationObjectSupport.setApplicationContext
      1. org.springframework.context.support.ApplicationObjectSupport.setApplicationContext(ApplicationObjectSupport.java:79)
      1 frame
    7. Spring MVC
      FrameworkServlet.service
      1. org.springframework.web.servlet.view.AbstractCachingViewResolver.loadAndConfigureView(AbstractCachingViewResolver.java:123)
      2. org.springframework.web.servlet.view.AbstractCachingViewResolver.resolveViewName(AbstractCachingViewResolver.java:78)
      3. org.springframework.web.servlet.DispatcherServlet.render(DispatcherServlet.java:629)
      4. org.springframework.web.servlet.DispatcherServlet.doService(DispatcherServlet.java:535)
      5. org.springframework.web.servlet.FrameworkServlet.service(FrameworkServlet.java:321)
      5 frames
    8. JavaServlet
      HttpServlet.service
      1. javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
      1 frame
    9. Glassfish Core
      ContainerBase.invoke
      1. org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:237)
      2. org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:157)
      3. org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:214)
      4. org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:104)
      5. org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520)
      6. org.apache.catalina.core.StandardContextValve.invokeInternal(StandardContextValve.java:198)
      7. org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:152)
      8. org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:104)
      9. org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520)
      10. org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:137)
      11. org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:104)
      12. org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:117)
      13. org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:102)
      14. org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520)
      15. org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
      16. org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:104)
      17. org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520)
      18. org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:929)
      18 frames
    10. org.apache.coyote
      CoyoteAdapter.service
      1. org.apache.coyote.tomcat5.CoyoteAdapter.service(CoyoteAdapter.java:160)
      1 frame
    11. Grizzly HTTP
      TcpWorkerThread.runIt
      1. org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:799)
      2. org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.processConnection(Http11Protocol.java:705)
      3. org.apache.tomcat.util.net.TcpWorkerThread.runIt(PoolTcpEndpoint.java:577)
      3 frames
    12. Tomcat Util
      ThreadPool$ControlRunnable.run
      1. org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:683)
      1 frame
    13. Java RT
      Thread.run
      1. java.lang.Thread.run(Thread.java:595)
      1 frame