Solved

Could you please give me the Log 4j code for this requirement

Posted on 2011-03-03
4
305 Views
Last Modified: 2012-08-13
use logger at the beginning and end of methods. So that we will be able to identify the error. In error log specify method name, table/component name
0
Comment
Question by:stmani2005
  • 3
4 Comments
 
LVL 86

Accepted Solution

by:
CEHJ earned 500 total points
ID: 35029976
You'd probably be better off putting in the method name manually to avoid the expense of getting the call stack
0
 
LVL 86

Expert Comment

by:CEHJ
ID: 35030045
Otherwise, see the 'M' parameter here: http://logging.apache.org/log4j/1.2/apidocs/org/apache/log4j/PatternLayout.html , which will automatically give you the method name
0
 
LVL 92

Expert Comment

by:objects
ID: 35031285
you cannot achieve that with log4j sorry.
you instead need something like aop
0
 
LVL 86

Expert Comment

by:CEHJ
ID: 35180110
:)
0

Featured Post

DevOps Toolchain Recommendations

Read this Gartner Research Note and discover how your IT organization can automate and optimize DevOps processes using a toolchain architecture.

Question has a verified solution.

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

Suggested Solutions

After being asked a question last year, I went into one of my moods where I did some research and code just for the fun and learning of it all.  Subsequently, from this journey, I put together this article on "Range Searching Using Visual Basic.NET …
Introduction This article is the second of three articles that explain why and how the Experts Exchange QA Team does test automation for our web site. This article covers the basic installation and configuration of the test automation tools used by…
Viewers learn about the third conditional statement “else if” and use it in an example program. Then additional information about conditional statements is provided, covering the topic thoroughly. Viewers learn about the third conditional statement …
This video teaches viewers about errors in exception handling.

773 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