You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@velocity.apache.org by Peter Lynch <pe...@mindspring.com> on 2001/10/18 01:17:00 UTC

Omission of autoload VMs in docs...

Was it a conscious decision to omit a reference to the autoload feature of
global vms from the documentation? Just realized it wasn't doc'ed there.

-Peter


Re: Omission of autoload VMs in docs...

Posted by "Geir Magnusson Jr." <ge...@optonline.net>.
On 10/18/01 11:00 PM, "Peter Lynch" <pe...@mindspring.com> wrote:

> I'll have a look at your doc entries now, but currently I can't get the
> Macros to reload without restarting tomcat, even with the setting to
> true....hmmmm.
> -Peter

I just tested it and it works.  I went back and found the announcement post,
so I am cleared of all charges of dereliction of duty :)  It says I will
document if people like.  No one said a peep.  You are peeping, so will
document :)

Here is the original post :

------------

There is a new property, meant to be used in *development*, not
production :

  velocimacro.library.autoreload

which defaults to false.

When set to true **ALONG WITH**

  <type>.resource.loader.cache = false

then the Velocity engine will automatically pick up changes to your
library files when you make them, so you do not have to dump the servlet
engine (or application) or do other tricks (like have a separate reload
for the vms...)

Give it a whirl - it seems reasonably solid and smart (ex it will only
reload a VM library once per modification, even if it has multiple VMs
that are used in different places...)

If people like it, I will document it.  If not, we'll fix or remove.

Don't keep this on in production :)

-----

Ok, so I just set it up, and it worked like a champ using tomcat 3.2.3 (the
version of which is irrelevant) and the lastest 1.3-dev jar (from CVS HEAD).
1.2-rc(1|2) should be the same.

My vel.props :

runtime.log = velocity.log

file.resource.loader.path = templates
file.resource.loader.cache = false

velocimacro.library.autoreload = true


The key is to make sure caching is off, as that will interfere with it.

I'll put this in the docs now.

Thanks for staying with it :)

geir

-- 
Geir Magnusson Jr.     geirm@optonline.net
System and Software Consulting
"They that can give up essential liberty to obtain a little temporary safety
deserve neither liberty nor safety." - Benjamin Franklin



Re: Omission of autoload VMs in docs...

Posted by Peter Lynch <pe...@mindspring.com>.
I'll have a look at your doc entries now, but currently I can't get the
Macros to reload without restarting tomcat, even with the setting to
true....hmmmm.
-Peter

----- Original Message -----
From: "Geir Magnusson Jr." <ge...@optonline.net>
To: <ve...@jakarta.apache.org>
Sent: Wednesday, October 17, 2001 4:27 PM
Subject: Re: Omission of autoload VMs in docs...


> On 10/17/01 7:22 PM, "Geir Magnusson Jr." <ge...@optonline.net> wrote:
>
> > On 10/17/01 7:20 PM, "Geir Magnusson Jr." <ge...@optonline.net> wrote:
> >
> >> On 10/17/01 7:17 PM, "Peter Lynch" <pe...@mindspring.com> wrote:
> >>
> >>> Was it a conscious decision to omit a reference to the autoload
feature of
> >>> global vms from the documentation? Just realized it wasn't doc'ed
there.
> >>>
> >>> -Peter
> >>>
> >>
> >>
> >> It is - it should be - I did it myself.
> >>
> >> I will check.
> >
> > Hm. I can't find it.
> >
> > I will note it in the dev and user guides...
>
> How bizarre - apologies. I'm stunned.  I did write it the day the feature
> went in.  Hm...
>
> --
> Geir Magnusson Jr.     geirm@optonline.net
> System and Software Consulting
> "They that can give up essential liberty to obtain a little temporary
safety
> deserve neither liberty nor safety." - Benjamin Franklin
>
>


Re: Omission of autoload VMs in docs...

Posted by "Geir Magnusson Jr." <ge...@optonline.net>.
On 10/17/01 7:22 PM, "Geir Magnusson Jr." <ge...@optonline.net> wrote:

> On 10/17/01 7:20 PM, "Geir Magnusson Jr." <ge...@optonline.net> wrote:
> 
>> On 10/17/01 7:17 PM, "Peter Lynch" <pe...@mindspring.com> wrote:
>> 
>>> Was it a conscious decision to omit a reference to the autoload feature of
>>> global vms from the documentation? Just realized it wasn't doc'ed there.
>>> 
>>> -Peter
>>> 
>> 
>> 
>> It is - it should be - I did it myself.
>> 
>> I will check.
> 
> Hm. I can't find it.
> 
> I will note it in the dev and user guides...

How bizarre - apologies. I'm stunned.  I did write it the day the feature
went in.  Hm...

-- 
Geir Magnusson Jr.     geirm@optonline.net
System and Software Consulting
"They that can give up essential liberty to obtain a little temporary safety
deserve neither liberty nor safety." - Benjamin Franklin



Re: Omission of autoload VMs in docs...

Posted by "Geir Magnusson Jr." <ge...@optonline.net>.
On 10/17/01 7:20 PM, "Geir Magnusson Jr." <ge...@optonline.net> wrote:

> On 10/17/01 7:17 PM, "Peter Lynch" <pe...@mindspring.com> wrote:
> 
>> Was it a conscious decision to omit a reference to the autoload feature of
>> global vms from the documentation? Just realized it wasn't doc'ed there.
>> 
>> -Peter
>> 
> 
> 
> It is - it should be - I did it myself.
> 
> I will check.

Hm. I can't find it.

I will note it in the dev and user guides...

-- 
Geir Magnusson Jr.     geirm@optonline.net
System and Software Consulting
"They that can give up essential liberty to obtain a little temporary safety
deserve neither liberty nor safety." - Benjamin Franklin



Re: Omission of autoload VMs in docs...

Posted by "Geir Magnusson Jr." <ge...@optonline.net>.
On 10/17/01 7:17 PM, "Peter Lynch" <pe...@mindspring.com> wrote:

> Was it a conscious decision to omit a reference to the autoload feature of
> global vms from the documentation? Just realized it wasn't doc'ed there.
> 
> -Peter
> 


It is - it should be - I did it myself.

I will check.

-- 
Geir Magnusson Jr.                       geirm@optonline.net
System and Software Consulting
You're going to end up getting pissed at your software
anyway, so you might as well not pay for it. Try Open Source.