Return-Path: Delivered-To: apmail-logging-log4net-user-archive@www.apache.org Received: (qmail 54655 invoked from network); 2 Sep 2009 17:55:25 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.3) by minotaur.apache.org with SMTP; 2 Sep 2009 17:55:25 -0000 Received: (qmail 8464 invoked by uid 500); 2 Sep 2009 17:55:25 -0000 Delivered-To: apmail-logging-log4net-user-archive@logging.apache.org Received: (qmail 8401 invoked by uid 500); 2 Sep 2009 17:55:25 -0000 Mailing-List: contact log4net-user-help@logging.apache.org; run by ezmlm Precedence: bulk list-help: list-unsubscribe: List-Post: Reply-To: "Log4NET User" List-Id: Delivered-To: mailing list log4net-user@logging.apache.org Received: (qmail 8392 invoked by uid 99); 2 Sep 2009 17:55:25 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 02 Sep 2009 17:55:25 +0000 X-ASF-Spam-Status: No, hits=-0.0 required=10.0 tests=SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (nike.apache.org: domain of mike.schall@gmail.com designates 209.85.221.182 as permitted sender) Received: from [209.85.221.182] (HELO mail-qy0-f182.google.com) (209.85.221.182) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 02 Sep 2009 17:55:13 +0000 Received: by qyk12 with SMTP id 12so463981qyk.6 for ; Wed, 02 Sep 2009 10:54:52 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:received:in-reply-to:references :date:message-id:subject:from:to:content-type :content-transfer-encoding; bh=h3g1T+Zkf5OU95JOHV3+MPxCvmuTWNAFvGH/w3xpB4c=; b=BVHVa7KezqNOPuue3CQCNLM7H8hSwgML/WZdvPUl8L3cD2X9L/Bzh8dRjxG1r0DIIH aqsl32CE7tibC9f4f5i9sUxY6u8oLisNFmIVINPXGEseVnJUAKRa4OvYjebXTiyLx2o2 NKUdceh8YSTz9mxwsLgzcZ0o9TuWdJ6LnFHUw= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :content-type:content-transfer-encoding; b=PWyvFBKPJI28DIqLXl353RkuLVRHDlD5V75V33ZE3UCGHqEKcWZc/Jfso3bVuO9NFA KJN8OqNhcSlx+DM4brAfjzZdITzOpe8VVGXXvStz/I7F10aF0G7lIBtmL9HdNI8GjhLJ EwZOJAIS1xI5QXq+UCQBtSQHPYqNn2OXYfLqw= MIME-Version: 1.0 Received: by 10.224.52.221 with SMTP id j29mr5559095qag.347.1251914092431; Wed, 02 Sep 2009 10:54:52 -0700 (PDT) In-Reply-To: <25259981.post@talk.nabble.com> References: <25259981.post@talk.nabble.com> Date: Wed, 2 Sep 2009 12:54:52 -0500 Message-ID: <5f9068320909021054g4993014s172d0f4a75ea29d9@mail.gmail.com> Subject: Re: forced log From: Michael Schall To: Log4NET User Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable X-Virus-Checked: Checked by ClamAV on apache.org You could define a separate logger for your the ones you always want log... logger =3D log4net.LogManager.GetLogger("AlwaysLog") logger.info("hello world") Depending on how you usually get a logger... .GetLogger(GetType(Foo)) This has the downside of not knowing which class you are logging from... Might work for your circumstance... Mike On Wed, Sep 2, 2009 at 10:36 AM, scamper_22 wrote: > > Hi all, > > I'm looking for a way to force a log without using Fatal. > For example, let us say I want to print a log with the application name a= nd > version. =A0I want this printed regardless of what the log level is. > > Right now, I am just using the fatal log level. =A0The problem with this = is it > ruins some of the data collection we have where we have a count of the > number of errors/fatal logs. > > Is there some way to do a logger.ForcedLog( INFO, "my string") ? =A0Which > basically ignores the priority of the message, but still logs it? > > I have see this ForcedLog API in log4j > (http://logging.apache.org/log4j/1.2/apidocs/index.html) > but it does not seem to in log4net (1.2.10.0). > > Thanks, > > > > > -- > View this message in context: http://www.nabble.com/forced-log-tp25259981= p25259981.html > Sent from the Log4net - Users mailing list archive at Nabble.com. > >