Apologies if this message gets posted more than once, this my first time using
the mailing list, and I am trying to figure out the correct address:
I have created a custom level that works as far as logging is concerned, but is
ignored when set as a threshold.
The level is defined as follows:
public class BusinessLevel extends Level
{
//Business Level Integer Values
public static final int BUSINESS_INT = FATAL_INT + 10000;
//Business Levels
public static final Level BUSINESS = new BusinessLevel(BUSINESS_INT,
"BUSINESS", SyslogAppender.LOG_LOCAL0);
/**
* Constructor
*
* @param level
* @param levelStr
* @param syslogEquivalent
*/
public BusinessLevel(int level, String levelStr, int syslogEquivalent)
{
super(level, levelStr, syslogEquivalent);
}
}
When I set the threshold to fatal, both fatal and business errors are logged.
This is correct. But when I set the threshold to business, all levels are
logged.
My appender config is as follows:
<appender name="CONSOLE" class="org.apache.log4j.ConsoleAppender">
<param name="Target" value="System.out"/>
<param name="Threshold" value="Business#BusinessLevel"/>
<layout class="org.apache.log4j.PatternLayout">
<!-- The default pattern: Date Priority [Category] Message\n -->
<param name="ConversionPattern" value="%d{ABSOLUTE} %-5p [%c{1}]
%m%n"/>
</layout>
</appender>
What am I doing wrong?
Any help would be much apprecieated.
Regards
Jamie
-----Original Message-----
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED]
Sent: 23 March 2006 11:43
To: Cash, Jamie
Subject: WELCOME to [email protected]
Hi! This is the ezmlm program. I'm managing the
[email protected] mailing list.
I'm working for my owner, who can be reached
at [EMAIL PROTECTED]
Acknowledgment: I have added the address
[EMAIL PROTECTED]
to the log4j-user mailing list.
Welcome to [EMAIL PROTECTED]
Please save this message so that you know the address you are
subscribed under, in case you later want to unsubscribe or change your
subscription address.
--- Administrative commands for the log4j-user list ---
I can handle administrative requests automatically. Please
do not send them to the list address! Instead, send
your message to the correct command address:
To subscribe to the list, send a message to:
<[EMAIL PROTECTED]>
To remove your address from the list, send a message to:
<[EMAIL PROTECTED]>
Send mail to the following for info and FAQ for this list:
<[EMAIL PROTECTED]>
<[EMAIL PROTECTED]>
Similar addresses exist for the digest list:
<[EMAIL PROTECTED]>
<[EMAIL PROTECTED]>
To get messages 123 through 145 (a maximum of 100 per request), mail:
<[EMAIL PROTECTED]>
To get an index with subject and author for messages 123-456 , mail:
<[EMAIL PROTECTED]>
They are always returned as sets of 100, max 2000 per request,
so you'll actually get 100-499.
To receive all messages with the same subject as message 12345,
send an empty message to:
<[EMAIL PROTECTED]>
The messages do not really need to be empty, but I will ignore
their content. Only the ADDRESS you send to is important.
You can start a subscription for an alternate address,
for example "[EMAIL PROTECTED]", just add a hyphen and your
address (with '=' instead of '@') after the command word:
<[EMAIL PROTECTED]>
To stop subscription for this address, mail:
<[EMAIL PROTECTED]>
In both cases, I'll send a confirmation message to that address. When
you receive it, simply reply to it to complete your subscription.
If despite following these instructions, you do not get the
desired results, please contact my owner at
[EMAIL PROTECTED] Please be patient, my owner is a
lot slower than I am ;-)
--- Enclosed is a copy of the request I received.
Return-Path: <[EMAIL PROTECTED]>
Received: (qmail 55519 invoked by uid 99); 23 Mar 2006 11:42:33 -0000
Received: from asf.osuosl.org (HELO asf.osuosl.org) (140.211.166.49)
by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 23 Mar 2006 03:42:33 -0800
X-ASF-Spam-Status: No, hits=1.3 required=10.0
tests=MISSING_SUBJECT
X-Spam-Check-By: apache.org
Received-SPF: pass (asf.osuosl.org: local policy)
Received: from [193.129.11.67] (HELO efmailgw02.ifdsgroup.co.uk) (193.129.11.67)
by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 23 Mar 2006 03:42:32 -0800
Received: from IFMAILSRV1.Mail.ifdsgroup.co.uk (unverified) by
efmailgw02.ifdsgroup.co.uk (Content Technologies SMTPRS 4.3.12) with
ESMTP id <[EMAIL PROTECTED]> for
<[EMAIL PROTECTED]>
; Thu, 23 Mar 2006 11:46:51 +0000
content-class: urn:content-classes:message
Return-Receipt-To: "Cash, Jamie" <[EMAIL PROTECTED]>
MIME-Version: 1.0
Content-Type: text/plain; charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable
Disposition-Notification-To: "Cash, Jamie" <[EMAIL PROTECTED]>
X-MimeOLE: Produced By Microsoft Exchange V6.0.6249.0
Subject:
Date: Thu, 23 Mar 2006 11:42:01 -0000
Message-ID: <[EMAIL PROTECTED]>
X-MS-Has-Attach:
X-MS-TNEF-Correlator:
Thread-Index: AcZObsxqULVtEJl9SkySrhurDC/SmQ==
From: "Cash, Jamie" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
X-Virus-Checked: Checked by ClamAV on apache.org
__________________________
I N T E R N A T I O N A L F I N A N C I A L D A T A S E R V I C ES
=
=20
Jamie Cash
Architecture Group
IFDS House, St Nicholas Lane, Basildon, SS15 5FS
Tel: 01268 44 3739
email: [EMAIL PROTECTED]
_______________________________
INTERNATIONAL FINANCIAL DATA SERVICES (UK) LTD Tel: +44 1268 44 3000
********************** N O T I C E *********************************
This message and any attachments is intended only for the individual or com=
pany to which it is addressed and may contain
information which is privileged, confidential or prohibited from disclosure=
or unauthorised use. If the recipient of this
transmission is not the intended recipient, or the employee or agent respon=
sible for delivering such materials to the
intended recipient, you are hereby notified that any use, any form of repro=
duction, dissemination, copying, disclosure,=20
modification, distribution and/or publication of this e-mail message or its=
attachments other than by it's intended
recipient is strictly prohibited by the sender. If you have received it in =
error, please notify us immediately by=20
telephone on the number above and destroy the message and all copies in you=
r possession.
International Financial Data Services (UK) Ltd is authorised and regulated =
by the Financial Services Authority.
This footnote also confirms that this email message has been swept by MIMEs=
weeper for the presence of computer viruses.
**********************************************************************
INTERNATIONAL FINANCIAL DATA SERVICES (UK) LTD Tel: +44 1268 44 3000
********************** N O T I C E *********************************
This message and any attachments is intended only for the individual or company
to which it is addressed and may contain
information which is privileged, confidential or prohibited from disclosure or
unauthorised use. If the recipient of this
transmission is not the intended recipient, or the employee or agent
responsible for delivering such materials to the
intended recipient, you are hereby notified that any use, any form of
reproduction, dissemination, copying, disclosure,
modification, distribution and/or publication of this e-mail message or its
attachments other than by it's intended
recipient is strictly prohibited by the sender. If you have received it in
error, please notify us immediately by
telephone on the number above and destroy the message and all copies in your
possession.
International Financial Data Services (UK) Ltd is authorised and regulated by
the Financial Services Authority.
This footnote also confirms that this email message has been swept by
MIMEsweeper for the presence of computer viruses.
**********************************************************************
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]