velocity-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Justin Lawler" <justindlaw...@eircom.net>
Subject Re: Setting logging for Velocity singlton doesnt work
Date Fri, 08 Mar 2002 15:29:11 GMT
yea, it hasnt been initialised. I even called getProperty
(RuntimeConstants.RUNTIME_LOG_LOGSYSTEM) after initialising it and it
returns the same LogSystem implentation. it just doesnt use it for logging.
wierd but ive been through my code and the velocity code many times but i
cant find any reason why i would do this.

----- Original Message -----
From: Geir Magnusson Jr. <geirm@optonline.net>
To: <velocity-user@jakarta.apache.org>
Sent: Friday, March 08, 2002 3:27 PM
Subject: Re: Setting logging for Velocity singlton doesnt work


> On 3/8/02 10:22 AM, "Justin Lawler" <justindlawler@eircom.net> wrote:
>
> > Why is it that when I set a logging system for the VelocityEngine class
eg.
> >   VelocityEngine.setProperty (RuntimeConstants.RUNTIME_LOG_LOGSYSTEM,
new
> > LogSystemImpl());
> >
> > the logging works, but when i do the same for the Velocity singlton, eg.
> >   Velocity.setProperty (RuntimeConstants.RUNTIME_LOG_LOGSYSTEM, new
> > LogSystemImpl());
> >
> > it just resorts to the SimpleLog4JLogSystem. I had a good look through
the
> > code and I cant find any reason why it should do this.
>
> It should work just fine - the Singleton is just a static wrapper around
the
> same RuntimeImpl that the VelocityEngine uses.
>
> Are you sure that the singleton hasn't been initialized already?  Once
> Velocity.init() is called, no more configuration is allowed...
>
> --
> Geir Magnusson Jr.                                     geirm@optonline.net
> System and Software Consulting
>
> Age and treachery will always triumph over youth and talent
>
>
> --
> To unsubscribe, e-mail:
<mailto:velocity-user-unsubscribe@jakarta.apache.org>
> For additional commands, e-mail:
<mailto:velocity-user-help@jakarta.apache.org>
>
>


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


Mime
View raw message