Solved

How to remove the debug statements generated by struts

Posted on 2006-11-16
8
711 Views
Last Modified: 2012-06-27
Hi,

  I am getting lot of debug statements in the weblogic server log . In my log4j.xml and properties files i have made the logging to ERROR level, then also i am getting lot of debug statements in the server log and the application log looks fine. These r the samples of debug statements i am getting


2006-11-15 09:28:43,767 [main] DEBUG org.apache.commons.beanutils.PropertyUtils - setSimpleProperty: Invoking method public void org.apache.struts.config.ActionConfig.setParameter(java.lang.String) with value list-64 (class java.lang.String)
2006-11-15 09:28:43,767 [main] DEBUG org.apache.commons.digester.Digester -   Fire begin() for SetNextRule[methodName=addActionConfig, paramType=org.apache.struts.config.ActionConfig]
2006-11-15 09:28:43,767 [main] DEBUG org.apache.commons.digester.Digester.sax - ignorableWhitespace(
                    )
2006-11-15 09:28:43,768 [main] DEBUG org.apache.commons.digester.Digester.sax - startElement(,forward,forward)
2006-11-15 09:28:43,768 [main] DEBUG org.apache.commons.digester.Digester -   Pushing body text ''
2006-11-15 09:28:43,768 [main] DEBUG org.apache.commons.digester.Digester -   New match='struts-config/action-mappings/action/forward'
2006-11-15 09:28:43,768 [main] DEBUG org.apache.commons.digester.Digester -   Fire begin() for FactoryCreateRule[className=null, attributeName=null, creationFactory=org.apache.struts.config.ActionForwardFactory@1f89e1]
2006-11-15 09:28:43,768 [main] DEBUG org.apache.commons.digester.Digester - [FactoryCreateRule]{struts-config/action-mappings/action/forward} New org.apache.struts.action.ActionForward
2006-11-15 09:28:43,768 [main] DEBUG org.apache.commons.digester.Digester -   Fire begin() for SetPropertiesRule[]
2006-11-15 09:28:43,768 [main] DEBUG org.apache.commons.digester.Digester - [SetPropertiesRule]{struts-config/action-mappings/action/forward} Setting property 'name' to 'list'
2006-11-15 09:28:43,768 [main] DEBUG org.apache.commons.digester.Digester - [SetPropertiesRule]{struts-config/action-mappings/action/forward} Setting property 'path' to '/jsp/approverequest/SearchAdminRequests.jsp'
2006-11-15 09:28:43,768 [main] DEBUG org.apache.commons.digester.Digester - [SetPropertiesRule]{struts-config/action-mappings/action/forward} Set org.apache.struts.action.ActionForward properties
2006-11-15 09:28:43,768 [main] DEBUG org.apache.commons.beanutils.BeanUtils - BeanUtils.populate(ForwardConfig[name=null,path=null,redirect=false,contextRelative=false,module=null], {path=/jsp/approverequest/SearchAdminRequests.jsp, name=list})
2006-11-15 09:28:43,769 [main] DEBUG org.apache.commons.beanutils.BeanUtils -   setProperty(ForwardConfig[name=null,path=null,redirect=false,contextRelative=false,module=null], path, /jsp/approverequest/SearchAdminRequests.jsp)
2006-11-15 09:28:43,769 [main] DEBUG org.apache.commons.beanutils.ConvertUtils - Convert string '/jsp/approverequest/SearchAdminRequests.jsp' to class 'java.lang.String'
2006-11-15 09:28:43,769 [main] DEBUG org.apache.commons.beanutils.ConvertUtils -   Using converter org.apache.commons.beanutils.converters.StringConverter@173bb48
2006-11-15 09:28:43,769 [main] DEBUG org.apache.commons.beanutils.PropertyUtils - setSimpleProperty: Invoking method public void org.apache.struts.config.ForwardConfig.setPath(java.lang.String) with value /jsp/approverequest/SearchAdminRequests.jsp (class java.lang.String)
2006-11-15 09:28:43,769 [main] DEBUG org.apache.commons.beanutils.BeanUtils -   setProperty(ForwardConfig[name=null,path=/jsp/approverequest/SearchAdminR

How to stop these debug statements which are getting generated
0
Comment
Question by:gocoool
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
  • 2
8 Comments
 
LVL 92

Accepted Solution

by:
objects earned 225 total points
ID: 17960026
you still appear to have apache logging set at debug
0
 
LVL 23

Expert Comment

by:Ajay-Singh
ID: 17962101
you should set the logging level of the logger "org.apache.commons" to ERROR.
0
 

Author Comment

by:gocoool
ID: 17964955
Hi Ajay,objects,
 I have taken care of those things in my log4j.properties and log4j.xml... which i have attached respectively....Then also it is coming up.

log4j.category.org.apache.commons.digester.Digester=ERROR
log4j.category.org.apache.commons.digester.Digester.sax=ERROR
log4j.category.org.apache.commons.beanutils.PropertyUtils=ERROR
log4j.category.org.apache.commons.beanutils.BeanUtils=ERROR
log4j.category.org.apache.commons.beanutils.ConvertUtils=ERROR


<category name="org.apache.commons.digester.Digester">
              <priority value="ERROR" />
          <appender-ref ref="ARMFILE" />
    </category>
    <category name="org.apache.commons.digester.Digester.sax">
              <priority value="ERROR" />
          <appender-ref ref="ARMFILE" />
    </category>
    <category name="org.apache.commons.beanutils.PropertyUtils">
              <priority value="ERROR" />
          <appender-ref ref="ARMFILE" />
    </category>
    <category name="org.apache.commons.beanutils.BeanUtils">
              <priority value="ERROR" />
          <appender-ref ref="ARMFILE" />
    </category>
    <category name="org.apache.commons.beanutils.ConvertUtils">
              <priority value="ERROR" />
          <appender-ref ref="ARMFILE" />
    </category>

0
Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 
LVL 23

Expert Comment

by:Ajay-Singh
ID: 17966828
You mean you have both log4j.properties and log4j.xml in the classpath?
0
 

Author Comment

by:gocoool
ID: 17968293

Ya ajay....  these files are included in the ear files we are building
0
 
LVL 23

Assisted Solution

by:Ajay-Singh
Ajay-Singh earned 225 total points
ID: 17970393
You need either log4j.properties or log4j.xml, NOT both. You can use the following log4j.xml file:

    <category name="org.apache.commons.digester">
             <priority value="ERROR" />
            <appender-ref ref="ARMFILE" />
    </category>
    <category name="org.apache.commons.beanutils">
             <priority value="ERROR" />
         <appender-ref ref="ARMFILE" />
    </category>


Since log categories are hieratical, you don't have to keep classwise loggers.
0

Featured Post

Transaction Monitoring Vs. Real User Monitoring

Synthetic Transaction Monitoring Vs. Real User Monitoring: When To Use Each Approach? In this article, we will discuss two major monitoring approaches: Synthetic Transaction and Real User Monitoring.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

By the end of 1980s, object oriented programming using languages like C++, Simula69 and ObjectPascal gained momentum. It looked like programmers finally found the perfect language. C++ successfully combined the object oriented principles of Simula w…
Java had always been an easily readable and understandable language.  Some relatively recent changes in the language seem to be changing this pretty fast, and anyone that had not seen any Java code for the last 5 years will possibly have issues unde…
Viewers learn how to read error messages and identify possible mistakes that could cause hours of frustration. Coding is as much about debugging your code as it is about writing it. Define Error Message: Line Numbers: Type of Error: Break Down…
This tutorial covers a practical example of lazy loading technique and early loading technique in a Singleton Design Pattern.

734 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question