Announcement Announcement Module
Collapse
No announcement yet.
Strange Dispatcher error Page Title Module
Move Remove Collapse
X
Conversation Detail Module
Collapse
  • Filter
  • Time
  • Show
Clear All
new posts

  • Strange Dispatcher error

    Hi,

    We are trying to forward from index.jsp(welcome-page) to a page handeled by FreeMarker! In this page there is no link with the persistent layer but we get the following error :

    Code:
    2004-10-18 16:34:16,015 DEBUG [org.springframework.beans.factory.support.DefaultListableBeanFactory] Returning cached instance of singleton bean 'freemarkerConfig'
    2004-10-18 16:34:16,015 DEBUG [org.springframework.beans.factory.support.DefaultListableBeanFactory] Returning cached instance of singleton bean 'dataSource'
    2004-10-18 16:34:16,015 DEBUG [org.springframework.beans.factory.support.DefaultListableBeanFactory] Calling code asked for FactoryBean instance for name 'dataSource'
    2004-10-18 16:34:16,015 ERROR [org.springframework.web.servlet.DispatcherServlet] Could not complete request
    java.lang.ArrayIndexOutOfBoundsException: 1
    	at org.springframework.beans.factory.support.DefaultListableBeanFactory.getBeansOfType(DefaultListableBeanFactory.java:196)
    	at org.springframework.context.support.AbstractApplicationContext.getBeansOfType(AbstractApplicationContext.java:474)
    	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.freemarker.FreeMarkerView.initApplicationContext(FreeMarkerView.java:119)
    	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 sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
    	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
    	at java.lang.reflect.Method.invoke(Method.java:324)
    Any suggestions???
    Thanks!

  • #2
    This may be caused by a request from the DispatcherServlet for a single bean of a given type and it does not find it.
    Could you post the content of the configuration of your dispatcher servlet ?
    And does this error appear when you start the web app or only when you call your initial page ?

    Olivier

    Comment


    • #3
      Hi,

      This error appear when a I access the first page!

      Comment


      • #4
        Thanks for the help!
        But it seems that the problem was caused by the "abstract" attribute declared for the transaction bean we used in the petclinic 1.1.1 spirit.

        Comment

        Working...
        X