You are viewing a plain text version of this content. The canonical link for it is here.
Posted to log4j-user@logging.apache.org by log4jlog4j <ma...@yahoo.co.in> on 2011/03/28 21:46:02 UTC

Log4j debug for one method in application

Hi,
Just want to check can we set debug for any specific method in the
applciation using log4j. This will be very useful if we have this feature in
log4j so trying to check on this. 

I have a application running on production and to check on one very
complicated issue want to check if we can set debug for any specific method.
Due to volume and performance we dont want to do debug at applciation level
on production and we are not able to reproduce that on our test environment. 


-- 
View this message in context: http://old.nabble.com/Log4j-debug-for-one-method-in-application-tp31261571p31261571.html
Sent from the Log4j - Users mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: log4j-user-unsubscribe@logging.apache.org
For additional commands, e-mail: log4j-user-help@logging.apache.org


Re: Log4j debug for one method in application

Posted by log4jlog4j <ma...@yahoo.co.in>.

Thanks a lot. This is what I was lokking and able to implement this and
seeing it working.


Jacob Kjome wrote:
> 
> 
> You could set it to debug for a specific class logger without issue, no? 
> Wouldn't
> you be using that same logger for all methods in the class anyway? 
> Otherwise,
> create multiple logger named after the class and method and enable debug
> for the
> one you care about.
> 
> Jake
> 
> On 3/28/2011 1:46 PM, log4jlog4j wrote:
>> 
>> Hi,
>> Just want to check can we set debug for any specific method in the
>> applciation using log4j. This will be very useful if we have this feature
>> in
>> log4j so trying to check on this. 
>> 
>> I have a application running on production and to check on one very
>> complicated issue want to check if we can set debug for any specific
>> method.
>> Due to volume and performance we dont want to do debug at applciation
>> level
>> on production and we are not able to reproduce that on our test
>> environment. 
>> 
>> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: log4j-user-unsubscribe@logging.apache.org
> For additional commands, e-mail: log4j-user-help@logging.apache.org
> 
> 
> 

-- 
View this message in context: http://old.nabble.com/Log4j-debug-for-one-method-in-application-tp31261571p31270197.html
Sent from the Log4j - Users mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: log4j-user-unsubscribe@logging.apache.org
For additional commands, e-mail: log4j-user-help@logging.apache.org


Re: Log4j debug for one method in application

Posted by Jacob Kjome <ho...@visi.com>.
You could set it to debug for a specific class logger without issue, no?  Wouldn't
you be using that same logger for all methods in the class anyway?  Otherwise,
create multiple logger named after the class and method and enable debug for the
one you care about.

Jake

On 3/28/2011 1:46 PM, log4jlog4j wrote:
> 
> Hi,
> Just want to check can we set debug for any specific method in the
> applciation using log4j. This will be very useful if we have this feature in
> log4j so trying to check on this. 
> 
> I have a application running on production and to check on one very
> complicated issue want to check if we can set debug for any specific method.
> Due to volume and performance we dont want to do debug at applciation level
> on production and we are not able to reproduce that on our test environment. 
> 
> 

---------------------------------------------------------------------
To unsubscribe, e-mail: log4j-user-unsubscribe@logging.apache.org
For additional commands, e-mail: log4j-user-help@logging.apache.org