Win a copy of Java Concurrency Live Lessons this week in the Threads forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

Custom Levels in Log4j  RSS feed

 
Sudhakar Rao
Ranch Hand
Posts: 36
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,
I created one custom level. I want to know how to pass it in the log4j-config.properites file.
Thanks in Advance
Sudhakar
 
Jaikiran Pai
Sheriff
Posts: 10447
227
IntelliJ IDE Ubuntu
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I am not sure how will mention it in log4j.properties but i was able to get it working with log4j.xml as mentioned Create your own logging level in log4j
 
Carol Enderlin
drifter
Ranch Hand
Posts: 1364
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
after the custom level name include the "#" sign followed by the fully qualified name of the class.



See Prior discussion on this topic.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!