Products
Applications
Support
Company
How To Buy
Skip to main content (Press Enter).
Sign in
Skip auxiliary navigation (Press Enter).
Register
Skip main navigation (Press Enter).
Toggle navigation
Search Options
Home
Communities
All Communities
Application Networking and Security
Enterprise Software
Mainframe Software
Software Defined Edge
Symantec Enterprise
Tanzu
VMware Cloud Foundation
Blogs
All Blogs
Enterprise Software
Mainframe Software
Symantec Enterprise
VMware
Events
All Events
Enterprise Software
Mainframe Software
Symantec Enterprise
VMware
Water Cooler
Betas
Flings
Education
Groups
Enterprise Software
Mainframe Software
Symantec Enterprise
VMware
Members
vCenter
Cloud & SDDC
View Only
Community Home
Threads
Library
Events
Members
Back to discussions
Expand all
|
Collapse all
sort by most recent
sort by thread
Log Levels – LOG4J Jboss log files
Avi
Apr 10, 2008 02:35 AM
We have a JBoss based system that we intend to monitor with Hyperic. When setting alerts on log files ...
Matt5D
Apr 10, 2008 11:31 PM
Probably, or redirect your log4j appenders to a target that can be parsed out of the box. Note adding ...
Avi
Apr 11, 2008 04:32 AM
Thanks for the reply. I changed my source (as suggested) built and deployed the hq-product.jar to ...
BradFelmey
Apr 11, 2008 02:20 PM
http://jira.hyperic.com File a ticket, por favor.
Douglas MacEachern
Apr 23, 2008 04:25 AM
Hmm, I was about to check in a fix to include the TRACE level as debug.. but if there happens to be ...
Matt5D
Apr 23, 2008 06:38 PM
I'd vote for plugin property, then a user can map the l4j levels to the 4 levels recognized by hyperic ...
1.
Log Levels – LOG4J Jboss log files
0
Recommend
Avi
Posted Apr 10, 2008 02:35 AM
Reply
Reply Privately
Options Dropdown
We have a JBoss based system that we intend to monitor with Hyperic.
When setting alerts on log files entries we discovered that the available log levels don’t include the ‘TRACE’ level.
Unfortunately for us some error messages are logged from this system using the TRACE level (not a very good practice but that is the way this system was implemented).
Looking at HQ source code I found that ‘Log4JLogTrackPlugin’ class defines log levels as follows:
private static final String[] LOG_LEVELS = {
"FATAL,ERROR", //Error
"WARN", //Warning
"INFO", //Info
"DEBUG" //Debug
};
public String[] getLogLevelAliases() {
return LOG_LEVELS;
}
What would be the quickest way to enable us including log events with ‘TRACE’ level? (Edit the above, build and use the modified jar?)
Any suggestions will be greatly appreciated.
2.
RE: Log Levels – LOG4J Jboss log files
1
Recommend
Matt5D
Posted Apr 10, 2008 11:31 PM
Reply
Reply Privately
Options Dropdown
Probably, or redirect your log4j appenders to a target that can be parsed out of the box. Note adding a 5th element to that array looks like it will get you an illegalargumentexception from the superclass. Do it as "DEBUG, TRACE" the same way fatal and error are grouped together.
3.
RE: Log Levels – LOG4J Jboss log files
0
Recommend
Avi
Posted Apr 11, 2008 04:32 AM
Reply
Reply Privately
Options Dropdown
Thanks for the reply.
I changed my source (as suggested) built and deployed the hq-product.jar to the corresponding agent and it worked.
I assume this can be raised as a defect, so new versions of HQ will be able to alert on TRACE output.
Cheers,
Avi
4.
RE: Log Levels – LOG4J Jboss log files
0
Recommend
BradFelmey
Posted Apr 11, 2008 02:20 PM
Reply
Reply Privately
Options Dropdown
http://jira.hyperic.com
File a ticket, por favor.
5.
RE: Log Levels – LOG4J Jboss log files
0
Recommend
Broadcom Employee
Douglas MacEachern
Posted Apr 23, 2008 04:25 AM
Reply
Reply Privately
Options Dropdown
Hmm, I was about to check in a fix to include the TRACE level as debug.. but if there happens to be anyone currently monitoring at DEBUG they may start getting flooded with otherwise unwanted TRACE messages. I think that may have been why TRACE was left out in the first place, normally just used for developer/debugging, not so much for release? The plugin just uses a substring to filter based on the level, so if you could just get the string DEBUG into all the trace messages you'd be set ;) We could also have a plugin property or agent.properties for this, just not sure about flipping it on by default. Open to suggestions here.
6.
RE: Log Levels – LOG4J Jboss log files
0
Recommend
Matt5D
Posted Apr 23, 2008 06:38 PM
Reply
Reply Privately
Options Dropdown
I'd vote for plugin property, then a user can map the l4j levels to the 4 levels recognized by hyperic in any way they choose. e.g., for a development/demo/beta type of instance you may want it to look like:
String[] LOG_LEVELS = {
"FATAL,ERROR", //Error
"WARN,INFO", //Warning
"DEBUG", //Info
"TRACE" //Debug
};
×
New Best Answer
This thread already has a best answer. Would you like to mark this message as the new best answer?
Copyright 2024. All rights reserved.
Powered by Higher Logic