james-server-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Noel J. Bergman" <n...@devtech.com>
Subject RE: Finer Logging Control for Mailets/Matchers
Date Sat, 08 Jun 2002 16:48:32 GMT
Danny,

I agree ... so please explain exactly how this "wrapper interface" would
differ from the logger facade in org.apache.avalon.framework.logger.  Are
you simply saying that you want to put a facade over their facade so that
the naming space is part of the Mailet API instead of Avalon?

> I'm not convinced that a getLogger method is appropriate for the API if it
> is going to make the mailet API depend upon any particular logging product

That's fine, but please explain how that independence precludes:

   public org.apache.mailet.Logger
org.apache.mailet.MailetContext.getLogger()

All you've asked is that Mailets not depend upon anything other than
org.apache.mailet.*, java.*, and javax.mail.*.  If you want GenericMailet to
also implement org.apache.mailet.Logger for convenience, that's fine.

If you want an org.apache.mailet.Logger facade over Avalon's logger, I'll be
happy to code and submit.  That would add the desired functionality, and
provide a start to improving Mailet interface independence.

When doing this, I propose adding a private MailetContext inner class to the
James class.  No one will see the class.  It will simply be used by
getMailetContext to wrap James, and provide a proper MailetContext interface
to Mailets.   The inner class will provide the interface, but delegate
functionality.  That will clean up some composition issues.

	--- Noel

-----Original Message-----
From: Danny Angus [mailto:danny@apache.org]
Sent: Saturday, June 08, 2002 12:05
To: James Developers List
Subject: RE: Finer Logging Control for Mailets/Matchers


I believe that there should probably be a wrapper interface in the API which
would allow implementors to use any logging product, and a very small set of
methods say: debug(),info(),warn(),error(),setLogLevel(), available to each
mailet/matcher.

I can't see any need for any other methods, can you?

d.

> -----Original Message-----
> From: Noel J. Bergman [mailto:noel@devtech.com]
> Sent: 07 June 2002 14:54
> To: James Developers List
> Subject: RE: Finer Logging Control for Mailets/Matchers
>
>
> Fair enough.  :-)  So what ideas do people have with respect
> specifically to how matchers and mailets should have access
> to logging services?
>
> 	--- Noel
>
> -----Original Message-----
> From: Serge Knystautas [mailto:sergek@lokitech.com]
> Sent: Friday, June 07, 2002 9:39
> To: James Developers List
> Subject: Re: Finer Logging Control for Mailets/Matchers
>
>
> Yes, I'm not happy with that change just yet.  This requires a change to
> the mailet API, which is something I want to discuss much more before
> changing.  We have this issue to change when we do make a new version of
> the mailet API.
> --
> Serge Knystautas
> Loki Technologies - Unstoppable Websites
> http://www.lokitech.com
>
> Noel J. Bergman wrote:
> > Andrei,
> >
> > I'll be happy to do the code, but does anyone else want it, and
> are people
> > OK with a MailetContext.getMailetLogger() method?  I'd just as soon not
> > submit a change that gets bitbucketed.
> >
> > 	--- Noel
> >
> > -----Original Message-----
> > From: Andrei A. Ivanov [mailto:myfam@surfeu.fi]
> > Sent: Friday, June 07, 2002 9:25
> > To: James Developers List
> > Subject: Re: Finer Logging Control for Mailets/Matchers
> >
> > Hi,
> >
> >
> >>We could expose
> >>MailetContext.getMailetLogger()
> >
> >
> > Let's do it, the sooner the better.
> >
> > What about other ideas: like make it possible to specify per
> mailet logger
> > etc?
> >
> > Andrei
> >
> > ----- Original Message -----
> > From: "Noel J. Bergman" <noel@devtech.com>
> > To: "James Developers List" <james-dev@jakarta.apache.org>
> > Sent: Friday, June 07, 2002 4:04 PM
> > Subject: Finer Logging Control for Mailets/Matchers
> >
> >
> >>Andrei,
> >>
> >>James implements MailetContext.  MailetContext provides the two log
> >
> > methods
> >
> >>available to Mailets.  Those two methods use:
> >>
> >>        getMailetLogger().info(...);
> >>
> >>which is a private method of James.  We could expose
> >>MailetContext.getMailetLogger() for matchers and mailets that want finer
> >>control over the log level.
> >>
> >>--- Noel
>
>
>
> --
> To unsubscribe, e-mail:
<mailto:james-dev-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:james-dev-help@jakarta.apache.org>


--
To unsubscribe, e-mail:   <mailto:james-dev-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:james-dev-help@jakarta.apache.org>


--
To unsubscribe, e-mail:   <mailto:james-dev-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:james-dev-help@jakarta.apache.org>


--
To unsubscribe, e-mail:   <mailto:james-dev-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:james-dev-help@jakarta.apache.org>


Mime
View raw message