1 2 Previous Next 16 Replies Latest reply on Nov 23, 2010 2:08 AM by jaikiran pai

    class loading issue in Jboss5.1.0

    Anu Radha Newbie

      Hi,

      I am working on upgrading Jboss 4.0.5 to jboss5.1.0 GA

      The application is working fine on jboss4 from past 2 years. Due to security issues, I have decided to upgrade the server to version 5.

      Now, the issue is, when I start the Jboss, It is loading all the .jar files,

      In my application, I have a jar file by name "m-r-framework-2.0.jar".

      m-r-framework-2.0.jar is loading,. But, few class files in that jar file are not loading.( Complete class files are not loaded). I came to know about it when, I opened jboss home page-> in JMX console->I could find that m-r-framework-2.0.jar is loaded, but, only few files are loaded, not complete.

      Can anyone please help me to figure out why ?

       

      Please help

       

      Regards,

      Anu

       

       

        • 1. Re: class loading issue in Jboss5.1.0
          jaikiran pai Master

          Server will not load all the classes. Only the required classes will be loaded. What exact issue are you running into.

          • 2. Re: class loading issue in Jboss5.1.0
            Anu Radha Newbie

            Hi Jai,

            Thank you for your reply.

             

            When i run the application on this server with partially loaded class files (class files in .jar), i am getting error. So, complete loading of above mentioned .jar file is important for me.

            Please help me to fix it.

             

            Regards,

            Anu

            • 3. Re: class loading issue in Jboss5.1.0
              jaikiran pai Master

              Please post the entire exception stacktrace that you are seeing. When does the exception occur?

              • 4. Re: class loading issue in Jboss5.1.0
                Anu Radha Newbie

                Hi Jai,

                I wanted to post the entire exception stack trace, but, nothing is getting printed in log file.  There is no server.log file at all! Can you please help me ?

                I have restarted the server,  no use,  I have deleted existing log folder and manually created it and then restarted server, still no use. All these days it was working fine. suddenly, i don't know what went wrong.

                 

                Regards,

                Anu

                • 5. Re: class loading issue in Jboss5.1.0
                  Wolf-Dieter Fink Master

                  Do you change the .../conf/jboss-log4j.xml?

                  It looks like a wrong logging configuration.

                  How do you start the JBoss? What do you change?

                  • 6. Re: class loading issue in Jboss5.1.0
                    Anu Radha Newbie

                    I have not changed anything. To start the server, I go to  D:\jboss-5.1.0.GA\bin,, in command prompt, i give run.bat.

                    • 7. Re: class loading issue in Jboss5.1.0
                      Anu Radha Newbie

                      hi Fink,

                      Now, i could see the log file.  Jboss_Home was pointing to older version of Jboss. So, it was not printing anything in Jboss5.

                      • 8. Re: class loading issue in Jboss5.1.0
                        Anu Radha Newbie

                        Hi

                        I am using Spring frame work. I have deployed on .ear file of  our application on Jboss5.

                        Server starts without any errors in 4m.

                         

                        When I try to run my application on the new server, it is giving  following error-stack Trace:

                        [code]

                         

                        010-11-22 01:13:47,944 INFO  [org.springframework.context.support.ClassPathXmlApplicationContext] (http-127.0.0.1-8080-1) Unable to locate MessageSource with name 'messageSource': using default [org.springframework.context.support.DelegatingMessageSource@87c2f5]

                        2010-11-22 01:13:47,944 INFO  [org.springframework.context.support.ClassPathXmlApplicationContext] (http-127.0.0.1-8080-1) Unable to locate ApplicationEventMulticaster with name 'applicationEventMulticaster': using default [org.springframework.context.event.SimpleApplicationEventMulticaster@11085f9]

                        2010-11-22 01:13:47,944 INFO  [org.springframework.beans.factory.support.DefaultListableBeanFactory] (http-127.0.0.1-8080-1) Pre-instantiating singletons in factory [org.springframework.beans.factory.support.DefaultListableBeanFactory defining beans []; root of BeanFactory hierarchy]

                        2010-11-22 01:13:47,944 WARN  [com.religare.apl.soa.mrf.transport.http.HttpReceiverServlet] (http-127.0.0.1-8080-1) Unexpected error in the HttpReceiverServlet of MRF

                        org.springframework.beans.factory.NoSuchBeanDefinitionException: No bean named 'MessageReceiver' is defined

                              at org.springframework.beans.factory.support.DefaultListableBeanFactory.getBeanDefinition(DefaultListableBeanFactory.java:340)

                              at org.springframework.beans.factory.support.AbstractBeanFactory.getMergedBeanDefinition(AbstractBeanFactory.java:906)

                              at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:242)

                              at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:161)

                              at org.springframework.context.support.AbstractApplicationContext.getBean(AbstractApplicationContext.java:642)

                              at com.religare.apl.soa.mrf.util.MrfSpringBeanFactory.getBean(MrfSpringBeanFactory.java:41)

                              at com.religare.apl.soa.mrf.transport.http.HttpReceiverServlet.doPost(HttpReceiverServlet.java:56)

                              at javax.servlet.http.HttpServlet.service(HttpServlet.java:637)

                              at javax.servlet.http.HttpServlet.service(HttpServlet.java:717)

                              at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)

                              at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)

                              at org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)

                              at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)

                              at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)

                              at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:235)

                              at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)

                              at org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:190)

                              at org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:92)

                              at org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.process(SecurityContextEstablishmentValve.java:126)

                              at org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.invoke(SecurityContextEstablishmentValve.java:70)

                              at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)

                              at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)

                              at org.jboss.web.tomcat.service.jca.CachedConnectionValve.invoke(CachedConnectionValve.java:158)

                              at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)

                              at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:330)

                              at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:829)

                              at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:598)

                              at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447)

                              at java.lang.Thread.run(Thread.java:619)

                        2010-11-22 01:13:47,991 ERROR [STDERR] (http-127.0.0.1-8080-1) org.springframework.beans.factory.NoSuchBeanDefinitionException: No bean named 'MessageReceiver' is defined

                        2010-11-22 01:13:47,991 ERROR [STDERR] (http-127.0.0.1-8080-1)   at org.springframework.beans.factory.support.DefaultListableBeanFactory.getBeanDefinition(DefaultListableBeanFactory.java:340)

                        2010-11-22 01:13:47,991 ERROR [STDERR] (http-127.0.0.1-8080-1)   at org.springframework.beans.factory.support.AbstractBeanFactory.getMergedBeanDefinition(AbstractBeanFactory.java:906)

                        2010-11-22 01:13:47,991 ERROR [STDERR] (http-127.0.0.1-8080-1)   at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:242)

                        2010-11-22 01:13:47,991 ERROR [STDERR] (http-127.0.0.1-8080-1)   at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:161)

                        2010-11-22 01:13:47,991 ERROR [STDERR] (http-127.0.0.1-8080-1)   at org.springframework.context.support.AbstractApplicationContext.getBean(AbstractApplicationContext.java:642)

                        2010-11-22 01:13:47,991 ERROR [STDERR] (http-127.0.0.1-8080-1)   at com.religare.apl.soa.mrf.util.MrfSpringBeanFactory.getBean(MrfSpringBeanFactory.java:41)

                        2010-11-22 01:13:47,991 ERROR [STDERR] (http-127.0.0.1-8080-1)   at com.religare.apl.soa.mrf.transport.http.HttpReceiverServlet.doPost(HttpReceiverServlet.java:56)

                        2010-11-22 01:13:47,991 ERROR [STDERR] (http-127.0.0.1-8080-1)   at javax.servlet.http.HttpServlet.service(HttpServlet.java:637)

                        2010-11-22 01:13:48,007 ERROR [STDERR] (http-127.0.0.1-8080-1)   at javax.servlet.http.HttpServlet.service(HttpServlet.java:717)

                        2010-11-22 01:13:48,007 ERROR [STDERR] (http-127.0.0.1-8080-1)   at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)

                        2010-11-22 01:13:48,007 ERROR [STDERR] (http-127.0.0.1-8080-1)   at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)

                        2010-11-22 01:13:48,007 ERROR [STDERR] (http-127.0.0.1-8080-1)   at org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)

                        2010-11-22 01:13:48,007 ERROR [STDERR] (http-127.0.0.1-8080-1)   at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)

                        2010-11-22 01:13:48,007 ERROR [STDERR] (http-127.0.0.1-8080-1)   at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)

                        2010-11-22 01:13:48,007 ERROR [STDERR] (http-127.0.0.1-8080-1)   at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:235)

                        2010-11-22 01:13:48,007 ERROR [STDERR] (http-127.0.0.1-8080-1)   at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)

                        2010-11-22 01:13:48,007 ERROR [STDERR] (http-127.0.0.1-8080-1)   at org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:190)

                        2010-11-22 01:13:48,007 ERROR [STDERR] (http-127.0.0.1-8080-1)   at org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:92)

                        2010-11-22 01:13:48,007 ERROR [STDERR] (http-127.0.0.1-8080-1)   at org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.process(SecurityContextEstablishmentValve.java:126)

                        2010-11-22 01:13:48,007 ERROR [STDERR] (http-127.0.0.1-8080-1)   at org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.invoke(SecurityContextEstablishmentValve.java:70)

                        2010-11-22 01:13:48,007 ERROR [STDERR] (http-127.0.0.1-8080-1)   at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)

                        2010-11-22 01:13:48,007 ERROR [STDERR] (http-127.0.0.1-8080-1)   at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)

                        2010-11-22 01:13:48,007 ERROR [STDERR] (http-127.0.0.1-8080-1)   at org.jboss.web.tomcat.service.jca.CachedConnectionValve.invoke(CachedConnectionValve.java:158)

                        2010-11-22 01:13:48,007 ERROR [STDERR] (http-127.0.0.1-8080-1)   at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)

                        2010-11-22 01:13:48,022 ERROR [STDERR] (http-127.0.0.1-8080-1)   at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:330)

                        2010-11-22 01:13:48,022 ERROR [STDERR] (http-127.0.0.1-8080-1)   at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:829)

                        2010-11-22 01:13:48,022 ERROR [STDERR] (http-127.0.0.1-8080-1)   at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:598)

                        2010-11-22 01:13:48,022 ERROR [STDERR] (http-127.0.0.1-8080-1)   at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447)

                        2010-11-22 01:13:48,022 ERROR [STDERR] (http-127.0.0.1-8080-1)   at java.lang.Thread.run(Thread.java:619)

                        [/code]

                        • 9. Re: class loading issue in Jboss5.1.0
                          Anu Radha Newbie

                          Any one please help me to fix this error.

                           

                          Please

                          • 10. Re: class loading issue in Jboss5.1.0
                            Anu Radha Newbie

                            This question is not answered.  I am getting some bean related error when i run my application on Jboss5.

                            I am still expecting a solution from this forum experts.

                             

                            Regards,

                            Ashvini. S

                            • 11. Re: class loading issue in Jboss5.1.0
                              jaikiran pai Master

                              This doesn't appear to be a classloader issue. Atleast not from that exception stacktrace. It looks like Spring is trying to configure some bean and is running into an error due to some other missing spring bean. You'll have to figure out how Spring tries to find the bean and why it isn't able to find it.

                              • 12. Re: class loading issue in Jboss5.1.0
                                Anu Radha Newbie

                                Hi Jai,

                                Thank you for your reply.

                                As you said, it is trying to load some bean.  That what i wrote in my original post.

                                 

                                When I start the Jboss, It is loading all the .jar files,

                                In my application, I have a jar file by name "m-r-framework-2.0.jar".

                                m-r-framework-2.0.jar is loading,. But, few class files in that jar file are not loading.( Complete class files are not loaded). I came to know about it when, I opened jboss home page-> in JMX console->I could find that m-r-framework-2.0.jar is loaded, but, only few files are loaded, not complete.

                                 

                                Since that jar file is not loaded fully, i am getting error as given in my previous post.

                                 

                                Please help me.

                                 

                                Regards,

                                Anu

                                • 13. Re: class loading issue in Jboss5.1.0
                                  jaikiran pai Master

                                  Anu Radha wrote:

                                   

                                  Hi Jai,

                                  Thank you for your reply.

                                  As you said, it is trying to load some bean.  That what i wrote in my original post.

                                   

                                  When I start the Jboss, It is loading all the .jar files,

                                  In my application, I have a jar file by name "m-r-framework-2.0.jar".

                                  m-r-framework-2.0.jar is loading,. But, few class files in that jar file are not loading.( Complete class files are not loaded). I came to know about it when, I opened jboss home page-> in JMX console->I could find that m-r-framework-2.0.jar is loaded, but, only few files are loaded, not complete.

                                   

                                  Like I said, this isn't really about loading "few classes" in a jar file.

                                   

                                  Anu Radha wrote:

                                   


                                  Since that jar file is not loaded fully, i am getting error as given in my previous post.

                                   

                                  Why do you think it's not "fully loaded"? Because Spring complains about a missing bean? If that jar is available in classpath and if Spring is trying to load a class via the classloader, then surely it will find it. I have zero experience with Spring, so I don't know how Spring does it.

                                   

                                  org.springframework.beans.factory.NoSuchBeanDefinitionException: No bean  named 'MessageReceiver' is defined

                                   

                                  Where and how is the MessageReceiver Spring bean defined?

                                  • 14. Re: class loading issue in Jboss5.1.0
                                    Anu Radha Newbie

                                    Hi Jai,

                                    Thank you for the reply.

                                     

                                    The jar file by name "m-r-framework-2.0.jar" has "MessageReceiver" file in it.  That is the reason i am thinking like it might be the reason for error.

                                    1 2 Previous Next