4 Replies Latest reply on Feb 9, 2004 1:50 AM by pilhuhn

    System.out.println gives Error

    rmittal

      I am a beginner in J2EE and JBOSS. I have some debug messages in my servlet where i have used System.out.println. It works fine in other AS but when i run it in jBOSS 3.2.3, it gives an error message like "Source not found for LoggerStream.println(String)" and returns a Null pointer Exception from that point. Can anybody help ?

        • 1. Re: System.out.println gives Error
          pilhuhn

          It is perfectly legal to have printlns in servlets.
          Do you have in your app own logging classes, that are not present in JBoss / your app version on JBoss?

          • 2. Re: System.out.println gives Error
            rmittal

            Thanks for your reply.

            But i don't have any logging classes for my application. I am using simple log4j for this purpose.

            • 3. Re: System.out.println gives Error
              rmittal

              One more observation regarding this. I have a common.jar which is lying in my WEB-INF/lib directory. If i am having a Syste.out.println in any of these classes in jar file, then i am facing this problem. But if i am haing System.out.println in any of classes which are in WEB-INF/classes folder, that is working fine.

              • 4. Re: System.out.println gives Error
                pilhuhn

                I am not completely sure, but afair the apache commons*.jar rely on commons-logging.jar for their logging. So this sounds like commons-logging might be missing. Just add it to your WEB-INF/lib