Announcement Announcement Module
Collapse
No announcement yet.
fail init application when rewrite a .class Page Title Module
Move Remove Collapse
X
Conversation Detail Module
Collapse
  • Filter
  • Time
  • Show
Clear All
new posts

  • fail init application when rewrite a .class

    Hello all,

    i have an application that use Spring-1.0.2 in a WebSphere 4.0.
    when i start the application (oposicionesGestion) works well.
    but when i rewrite a update .class in the WEB-INF\classes, WebSphere try to restart the application and throws the exception:
    [2/09/04 11:50:37:059 CEST] 7f28d6f5 WebGroup I SRVE0091I: [Anotación de servlet]: oposicionesGestion: init
    [2/09/04 11:50:37:059 CEST] 7f28d6f5 WebGroup I SRVE0091I: [Anotación de servlet]: Initializing WebApplicationContext for servlet 'oposicionesGestion'
    [2/09/04 11:50:37:059 CEST] 7f28d6f5 ServletInstan X SRVE0100E: No se ha podido capturar la excepción init() lanzada por el servlet oposicionesGestion: javax.servlet.ServletException: Error creating bean with name 'dataSource' defined in URL [file:C:/wwwroot/oposicionesGestion/Recursos/dataAccessContext-jdbc.xml]: Error setting property values; nested exception is org.springframework.beans.PropertyAccessExceptions Exception: PropertyAccessExceptionsException (1 errors); nested propertyAccessExceptions are: [org.springframework.beans.TypeMismatchException: Failed to convert property value of type [org.springframework.jndi.JndiObjectFactoryBean] to required type [javax.sql.DataSource] for property 'dataSource'; nested exception is java.lang.IllegalArgumentException: argument type mismatch]
    at com.ibm.servlet.engine.webapp.StrictServletInstanc e.doInit(ServletManager.java:817)
    at com.ibm.servlet.engine.webapp.StrictLifecycleServl et._init(StrictLifecycleServlet.java:141)
    at com.ibm.servlet.engine.webapp.PreInitializedServle tState.init(StrictLifecycleServlet.java:254)
    at com.ibm.servlet.engine.webapp.StrictLifecycleServl et.init(StrictLifecycleServlet.java:107)
    at com.ibm.servlet.engine.webapp.ServletInstance.init (ServletManager.java:388)
    at javax.servlet.GenericServlet.init(GenericServlet.j ava:258)
    at com.ibm.servlet.engine.webapp.ServletManager.addSe rvlet(ServletManager.java:84)
    at com.ibm.servlet.engine.webapp.WebAppServletManager .loadServlet(WebAppServletManager.java:211)
    at com.ibm.servlet.engine.webapp.WebAppServletManager .getServletReference(WebAppServletManager.java:279 )
    at com.ibm.servlet.engine.webapp.WebApp.getServletRef erence(WebApp.java:388)
    at com.ibm.servlet.engine.webapp.WebAppRequestDispatc herInfo.calculateInfo(WebAppRequestDispatcherInfo. java:167)
    at com.ibm.servlet.engine.webapp.WebAppRequestDispatc herInfo.<init>(WebAppRequestDispatcherInfo.java:51 )
    at com.ibm.servlet.engine.webapp.WebApp.getRequestDis patcher(WebApp.java:1355)
    at com.ibm.servlet.engine.srt.WebAppInvoker.handleInv ocationHook(WebAppInvoker.java(Compiled Code))
    at com.ibm.servlet.engine.invocation.CachedInvocation .handleInvocation(CachedInvocation.java(Compiled Code))
    at com.ibm.servlet.engine.srp.ServletRequestProcessor .dispatchByURI(ServletRequestProcessor.java(Compil ed Code))
    at com.ibm.servlet.engine.oselistener.OSEListenerDisp atcher.service(OSEListener.java(Compiled Code))
    at com.ibm.servlet.engine.http11.HttpConnection.handl eRequest(HttpConnection.java(Compiled Code))
    at com.ibm.ws.http.HttpConnection.readAndHandleReques t(HttpConnection.java(Compiled Code))
    at com.ibm.ws.http.HttpConnection.run(HttpConnection. java(Compiled Code))
    at com.ibm.ws.util.CachedThread.run(ThreadPool.java(C ompiled Code))

    [2/09/04 11:50:37:090 CEST] 7f28d6f5 WebGroup X Servlet Error-[oposicionesGestion]: Error al cargar el servlet: org.springframework.beans.factory.BeanCreationExce ption: Error creating bean with name 'dataSource' defined in URL [file:C:/wwwroot/oposicionesGestion/Recursos/dataAccessContext-jdbc.xml]: Error setting property values; nested exception is org.springframework.beans.PropertyAccessExceptions Exception: PropertyAccessExceptionsException (1 errors); nested propertyAccessExceptions are: [org.springframework.beans.TypeMismatchException: Failed to convert property value of type [org.springframework.jndi.JndiObjectFactoryBean] to required type [javax.sql.DataSource] for property 'dataSource'; nested exception is java.lang.IllegalArgumentException: argument type mismatch]
    PropertyAccessExceptionsException (1 errors)
    org.springframework.beans.TypeMismatchException: Failed to convert property value of type [org.springframework.jndi.JndiObjectFactoryBean] to required type [javax.sql.DataSource] for property 'dataSource'; nested exception is java.lang.IllegalArgumentException: argument type mismatch
    java.lang.IllegalArgumentException: argument type mismatch
    at java.lang.reflect.Method.invoke(Native Method)
    at org.springframework.beans.BeanWrapperImpl.setPrope rtyValue(BeanWrapperImpl.java:649)
    at org.springframework.beans.BeanWrapperImpl.setPrope rtyValue(BeanWrapperImpl.java:568)
    at org.springframework.beans.BeanWrapperImpl.setPrope rtyValue(BeanWrapperImpl.java:685)
    at org.springframework.beans.BeanWrapperImpl.setPrope rtyValues(BeanWrapperImpl.java:712)
    at org.springframework.beans.BeanWrapperImpl.setPrope rtyValues(BeanWrapperImpl.java:701)
    at org.springframework.beans.factory.support.Abstract AutowireCapableBeanFactory.applyPropertyValues(Abs tractAutowireCapableBeanFactory.java:626)
    at org.springframework.beans.factory.support.Abstract AutowireCapableBeanFactory.populateBean(AbstractAu towireCapableBeanFactory.java:467)
    at org.springframework.beans.factory.support.Abstract AutowireCapableBeanFactory.createBean(AbstractAuto wireCapableBeanFactory.java:232)
    at org.springframework.beans.factory.support.Abstract AutowireCapableBeanFactory.createBean(AbstractAuto wireCapableBeanFactory.java:177)
    at org.springframework.beans.factory.support.Abstract BeanFactory.getBean(AbstractBeanFactory.java:159)
    at org.springframework.beans.factory.support.DefaultL istableBeanFactory.preInstantiateSingletons(Defaul tListableBeanFactory.java:183)
    at org.springframework.context.support.AbstractApplic ationContext.refresh(AbstractApplicationContext.ja va:268)
    at org.springframework.web.context.support.XmlWebAppl icationContext.refresh(XmlWebApplicationContext.ja va:131)
    at org.springframework.web.context.ContextLoader.crea teWebApplicationContext(ContextLoader.java:156)
    at org.springframework.web.context.ContextLoader.init WebApplicationContext(ContextLoader.java:97)
    at org.springframework.web.context.ContextLoaderServl et.init(ContextLoaderServlet.java:80)
    at javax.servlet.GenericServlet.init(GenericServlet.j ava:258)
    at com.ibm.servlet.engine.webapp.StrictServletInstanc e.doInit(ServletManager.java:802)
    at com.ibm.servlet.engine.webapp.StrictLifecycleServl et._init(StrictLifecycleServlet.java:141)
    at com.ibm.servlet.engine.webapp.PreInitializedServle tState.init(StrictLifecycleServlet.java:254)
    at com.ibm.servlet.engine.webapp.StrictLifecycleServl et.init(StrictLifecycleServlet.java:107)
    at com.ibm.servlet.engine.webapp.ServletInstance.init (ServletManager.java:388)
    at javax.servlet.GenericServlet.init(GenericServlet.j ava:258)
    at com.ibm.servlet.engine.webapp.ServletManager.addSe rvlet(ServletManager.java:84)
    at com.ibm.servlet.engine.webapp.WebAppServletManager .loadServlet(WebAppServletManager.java:211)
    at com.ibm.servlet.engine.webapp.WebAppServletManager .loadAutoLoadServlets(WebAppServletManager.java:35 0)
    at com.ibm.servlet.engine.webapp.WebApp.loadServletMa nager(WebApp.java:1217)
    at com.ibm.servlet.engine.webapp.WebApp.init(WebApp.j ava:145)
    at com.ibm.servlet.engine.srt.WebGroup.loadWebApp(Web Group.java:259)
    at com.ibm.servlet.engine.srt.WebGroup.reload(WebGrou p.java:1107)
    at com.ibm.servlet.engine.srt.ClassChangeWatcher.clas sChanged(ClassChangeWatcher.java:55)
    at com.ibm.ws.classloader.ClassLoaderManager.checkAnd Notify(ClassLoaderManager.java(Compiled Code))
    at com.ibm.ws.classloader.ClassLoaderManager.access$1 00(ClassLoaderManager.java(Inlined Compiled Code))
    at com.ibm.ws.classloader.ClassLoaderManager$ReloadTi merTask.run(ClassLoaderManager.java(Compiled Code))
    at java.util.TimerThread.mainLoop(Timer.java(Compiled Code))
    at java.util.TimerThread.run(Timer.java:395)
    then i have to restart the application (or websphere server) and works well again.

    which can be the problem?

    thanks in advance,
    César.

  • #2
    Any Fix found?

    Have you found a fix for this? It is very annoying--and becoming expensive--to have to restart the application server to deploy a change.

    Comment


    • #3
      Hello,
      No, i have to restart the server.
      Saludos,
      César.

      Comment


      • #4
        But not in debug mode !??

        I was trying to run a simple application in debug mode to pinpoint exactly where the error occurs. In debug mode within WSAD, the error didn't occur at all!

        Comment


        • #5
          StrutsPlugin Successfully Reloads

          Although the ContextLoaderServlet fails on a restart of the web application, the Struts ContextLoaderPlugin succeeds!

          If I remove the root context (by disabling the ContextLoaderServlet) and move all of the bean definitions to the action-servlet.xml descriptor, I am able to refresh the classes/jars used by the web application without having to restart the application server.

          Comment


          • #6
            Struts?

            Hello,

            Struts ContextLoaderPlugin? i use spring mvc, i can replace ContextLoaderServlet with this plugin and works?

            Cesar.

            Comment


            • #7
              RE: Struts?

              I may have posted too quickly. I was using the WAS 5.1 test environment; not WAS 4.0.
              I went back and tested with the 4.0 Test Environment, and the workaround did not work around the problem.
              It probably wouldn't help you much, though, if you aren't using Struts.

              Sorry.

              It is good to note, though, that the problem does not occur with WAS 5.1 (JDK 1.4.1).

              -joe

              Comment


              • #8
                thanks anyway, i hope that upgrade to was 5.1 early...

                Saludos,
                César.

                Comment


                • #9
                  same thing

                  same thing for me... it doesn't seem to be container-related, I'm using orion as my container and getting this when i redeploy my app

                  Comment

                  Working...
                  X