Solved

log4j, turning off logging in external library

Posted on 2006-06-16
2
288 Views
Last Modified: 2008-03-03
Hello,

I am using log4j in my own own code, and, I am using the ROME library for process RSS. Does anybody know what I should put in my log4j configuration file so that only my logger.debug(...) statements go to the output, but not the debug statements that are inside ROME?

Thanks,

Adrian.
0
Comment
Question by:adrianbasheer
[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
2 Comments
 
LVL 6

Accepted Solution

by:
phuocnh earned 250 total points
ID: 16926225
Hi  adrianbasheer!
I don't know about ROME library, I suppose that the library begins with org.rome or something is like that
if you use log4j.xml file you put the following lines
<category name="org.rome">
     <priority value="INFO"/> <-------you can use INFO, ERROR, WARN to prevent DEBUG information.
   </category>
into log4j.xml as the sub tag of <log4j:configuration> tag.
If you use log4j.properties you should use
log4j.category.org.rome = INFO, your_appender_name
Phuoc
0
 

Author Comment

by:adrianbasheer
ID: 16932774
Hi,

Thanks a lot for your answer, now I understand things better.

Adrian.
0

Featured Post

Enroll in May's Course of the Month

May’s Course of the Month is now available! Experts Exchange’s Premium Members and Team Accounts have access to a complimentary course each month as part of their membership—an extra way to increase training and boost professional development.

Question has a verified solution.

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

Suggested Solutions

Title # Comments Views Activity
how to see all occupied ports on windows 10 laptop 15 94
What's wrong with this code? 4 46
glassfish admin console 1 50
JDBC performance 8 35
For beginner Java programmers or at least those new to the Eclipse IDE, the following tutorial will show some (four) ways in which you can import your Java projects to your Eclipse workbench. Introduction While learning Java can be done with…
Java contains several comparison operators (e.g., <, <=, >, >=, ==, !=) that allow you to compare primitive values. However, these operators cannot be used to compare the contents of objects. Interface Comparable is used to allow objects of a cl…
Viewers learn about the “while” loop and how to utilize it correctly in Java. Additionally, viewers begin exploring how to include conditional statements within a while loop and avoid an endless loop. Define While Loop: Basic Example: Explanatio…
Viewers will learn about the different types of variables in Java and how to declare them. Decide the type of variable desired: Put the keyword corresponding to the type of variable in front of the variable name: Use the equal sign to assign a v…
Suggested Courses

739 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