public inbox for frysk@sourceware.org
 help / color / mirror / Atom feed
From: Andrew Cagney <cagney@redhat.com>
To: frysk <frysk@sourceware.org>
Subject: Re: a simpler logger [?]
Date: Mon, 11 Feb 2008 18:52:00 -0000	[thread overview]
Message-ID: <47B09909.4070707@redhat.com> (raw)
In-Reply-To: <4766D650.6080102@redhat.com>

FYI,

Much of frysk-sys is now using this logger; in switching my stack-smash 
bug seems to have gone back into hiding, sigh :-(

In using this logger, I've also made the following refinements:

-> The option is renamed to << -debug <what> >> rather than << -trace 
<what> >>; "trace" gets confusing when using tools such as ftrace (I'm 
not sure that -debug is much better though :-)

-> The option parser is far more (far too?) forgiving in what it 
accepts; for instance:
     -debug frysk.expunit                          -- default to level FINE
     -debug frysk.expunit=FINEST         -- explicit
     -debug FINE                                        -- global

-> The logger understands class inheritance - explicitly setting a super 
classes log-level automatically updates all sub-classes; for instance:
     -debug frysk.junit.TestCase             -- enables logging for all 
instances of TestCase including sub-classes.

Andrew

  
Andrew Cagney wrote:
> FYI,
>
> I've marked up frysk.expunit to use this logger (so people can see it 
> working).  Enable it with something like:
>   ./TestRunner -trace FINE frysk.hpd.TestLoadCommand
> or:
>  ./TtestRunner -trace frysk.expunit=FINEST  frysk.hpd.TestLoadCommand
>
> Andrew
>
> Andrew Cagney wrote:
>> Hi,
>>
>> I've just added a frysk.rsl (really simple logger?) package as a 
>> possible alternative to the java logging framework we're currently 
>> using.  The "advantages" as I'll spin them are:
>>
>> -> the logging call is unlocked (at least in the logger level)
>> so the ongoing saga of older log implementations deadlocking is avoided
>>
>> -> nested logging works
>>
>> -> it supports a completer interface
>> so that << (fhpd) frysk log frysk.proc.<TAB> >> can give a known list 
>> of loggers
>>
>> -> [I think] the call interface is simpler and lighter
>> for instance << log.fine(this, "adding foo") >> or << log.fine(this, 
>> "adding foo=", foo); >> (we can add more methods as we need them :-)
>>
>> thoughts?
>>
>> Andrew
>>
>

  reply	other threads:[~2008-02-11 18:52 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-12-07 16:37 Andrew Cagney
2007-12-17 20:05 ` Andrew Cagney
2008-02-11 18:52   ` Andrew Cagney [this message]
2008-02-12 12:15     ` Mark Wielaard
2008-02-12 12:23       ` Phil Muldoon
2008-02-12 13:29         ` Mark Wielaard

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=47B09909.4070707@redhat.com \
    --to=cagney@redhat.com \
    --cc=frysk@sourceware.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).