You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@turbine.apache.org by ps...@comcen.com.au on 2001/06/15 07:05:56 UTC

Are Macro libraries polled for changes?

Hello to all,
I've noticed that if I make a change to a Velocity Macro
library, that I have to restart Turbine for the changes to
take effect. Is this correct, or I have I misconfigured
something?
It is a pain to have to restart every time something is 
modified.


Changes to layouts and screen templates are detected 
no problems.

Thanks,

Patrick

---------------------------------------------------------------------
To unsubscribe, e-mail: turbine-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: turbine-user-help@jakarta.apache.org


Re: Are Macro libraries polled for changes?

Posted by ps...@comcen.com.au.
Thanks Keng,
I can appreciate why this is the case. Something
to do with the way Turbine has been built I gues..

I suppose the only solution is to debug your macros in
a test screen and then once validated, relocate back 
into the macro template file.

Patrick.

Quoting Keng Wong <ke...@verizon.net>:

> Patrick,
> Sorry if I've misled you. Currently there is no way of reloading macro 
> functions besides restarting turbine.
> 
> -keng wong
> 
> On Thursday 14 June 2001 11:43 pm, psaunder@comcen.com.au wrote:
> > Hi Keng,
> > I'm having a little difficulty understanding your answers. In your
> > prior post it sounded like you were saying it could be done, but
> > now it seems as if your saying I can't.
> >
> > I am trying to *avoid* restarting every time I modify a macro
> > function. Can this be done, or am I expecting to much?
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: turbine-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: turbine-user-help@jakarta.apache.org
> 
> 

---------------------------------------------------------------------
To unsubscribe, e-mail: turbine-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: turbine-user-help@jakarta.apache.org


Re: Are Macro libraries polled for changes?

Posted by Keng Wong <ke...@verizon.net>.
Patrick,
Sorry if I've misled you. Currently there is no way of reloading macro 
functions besides restarting turbine.

-keng wong

On Thursday 14 June 2001 11:43 pm, psaunder@comcen.com.au wrote:
> Hi Keng,
> I'm having a little difficulty understanding your answers. In your
> prior post it sounded like you were saying it could be done, but
> now it seems as if your saying I can't.
>
> I am trying to *avoid* restarting every time I modify a macro
> function. Can this be done, or am I expecting to much?

---------------------------------------------------------------------
To unsubscribe, e-mail: turbine-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: turbine-user-help@jakarta.apache.org


Re: Are Macro libraries polled for changes?

Posted by ps...@comcen.com.au.
Hi Keng,
I'm having a little difficulty understanding your answers. In your
prior post it sounded like you were saying it could be done, but
now it seems as if your saying I can't.

I am trying to *avoid* restarting every time I modify a macro
function. Can this be done, or am I expecting to much?

Patrick.


Quoting Keng Wong <ke...@verizon.net>:

> No, there isn't any polling for macro templates. The VM_global_lib.vm is
> read 
> by default and this is where you can store all your macros in one place.
> 
> Still it is only read once everytime velocity is started - must restart
> for 
> any changes to take effect.
> 
> -keng wong
> 
> On Thursday 14 June 2001 10:51 pm, psaunder@comcen.com.au wrote:
> > Hi Keng,
> > I am at work at the moment and can't delve into TRProps,
> > though are you saying that there is something special
> > about the VM_global_lib.vm that makes it get polled
> > but not my own?
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: turbine-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: turbine-user-help@jakarta.apache.org
> 
> 

---------------------------------------------------------------------
To unsubscribe, e-mail: turbine-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: turbine-user-help@jakarta.apache.org


Re: Are Macro libraries polled for changes?

Posted by Keng Wong <ke...@verizon.net>.
No, there isn't any polling for macro templates. The VM_global_lib.vm is read 
by default and this is where you can store all your macros in one place. 
Still it is only read once everytime velocity is started - must restart for 
any changes to take effect.

-keng wong

On Thursday 14 June 2001 10:51 pm, psaunder@comcen.com.au wrote:
> Hi Keng,
> I am at work at the moment and can't delve into TRProps,
> though are you saying that there is something special
> about the VM_global_lib.vm that makes it get polled
> but not my own?


---------------------------------------------------------------------
To unsubscribe, e-mail: turbine-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: turbine-user-help@jakarta.apache.org


Re: Are Macro libraries polled for changes?

Posted by ps...@comcen.com.au.
Hi Keng,
I am at work at the moment and can't delve into TRProps,
though are you saying that there is something special
about the VM_global_lib.vm that makes it get polled
but not my own?

I'm not doing any #parse or anything else fancy like that.

Thanks,

Patrick.
Quoting Keng Wong <ke...@verizon.net>:

> >From the docs, it is suppose to work this way (load all velocimacros
> and 
> store in cache). It is also important not to #parse any vm templates
> that 
> contain velocimacros. To get around this, simple put it in the 
> VM_global_lib.vm or use the velocimacro.library property.
> 
> On Thursday 14 June 2001 10:05 pm, psaunder@comcen.com.au wrote:
> > Hello to all,
> > I've noticed that if I make a change to a Velocity Macro
> > library, that I have to restart Turbine for the changes to
> > take effect. Is this correct, or I have I misconfigured
> > something?
> > It is a pain to have to restart every time something is
> > modified.
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: turbine-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: turbine-user-help@jakarta.apache.org
> 
> 

---------------------------------------------------------------------
To unsubscribe, e-mail: turbine-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: turbine-user-help@jakarta.apache.org


Re: Are Macro libraries polled for changes?

Posted by Keng Wong <ke...@verizon.net>.
>From the docs, it is suppose to work this way (load all velocimacros and 
store in cache). It is also important not to #parse any vm templates that 
contain velocimacros. To get around this, simple put it in the 
VM_global_lib.vm or use the velocimacro.library property.

On Thursday 14 June 2001 10:05 pm, psaunder@comcen.com.au wrote:
> Hello to all,
> I've noticed that if I make a change to a Velocity Macro
> library, that I have to restart Turbine for the changes to
> take effect. Is this correct, or I have I misconfigured
> something?
> It is a pain to have to restart every time something is
> modified.

---------------------------------------------------------------------
To unsubscribe, e-mail: turbine-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: turbine-user-help@jakarta.apache.org


Re: Are Macro libraries polled for changes?

Posted by ps...@comcen.com.au.
Many thanks Jason,
I will give it a shot tonight.

Patrick.

Quoting Jason van Zyl <jv...@apache.org>:

> On 6/15/01 1:05 AM, "psaunder@comcen.com.au" <ps...@comcen.com.au>
> wrote:
> 
> > Hello to all,
> > I've noticed that if I make a change to a Velocity Macro
> > library, that I have to restart Turbine for the changes to
> > take effect. Is this correct, or I have I misconfigured
> > something?
> > It is a pain to have to restart every time something is
> > modified.
> 
> Try this:
>  
> services.VelocityService.velocimacro.permissions.allow.inline.to.replace.glo
> bal = true
> 
> services.VelocityService.file.resource.loader.cache = false
> 
>  
> > Changes to layouts and screen templates are detected
> > no problems.
> > 
> > Thanks,
> > 
> > Patrick
> > 
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: turbine-user-unsubscribe@jakarta.apache.org
> > For additional commands, e-mail: turbine-user-help@jakarta.apache.org
> 
> -- 
> 
> jvz.
> 
> http://tambora.zenplex.org
> http://jakarta.apache.org/turbine
> http://jakarta.apache.org/velocity
> http://jakarta.apache.org/alexandria
> http://jakarta.apache.org/commons
> 
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: turbine-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: turbine-user-help@jakarta.apache.org
> 
> 

---------------------------------------------------------------------
To unsubscribe, e-mail: turbine-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: turbine-user-help@jakarta.apache.org


Re: Are Macro libraries polled for changes?

Posted by Keng Wong <ke...@verizon.net>.
You're right - it works. The doc needs an update ? 
If there is a typo, here's a patch for the xdocs:

--- user-guide.xml      Fri Jun 15 02:59:36 2001
+++ new-user-guide.xml  Fri Jun 15 03:00:47 2001
@@ -1326,7 +1326,7 @@
     </p>
 
     <p>
-    <code>velocimacro.permissions.allow.inline.to.override</code> -
+    <code>velocimacro.permissions.allow.inline.to.replace.global</code> -
      With possible values of true or false,
     this property allows the user to specify if a  Velocimacro defined
     inline in a template can replace a globally defined template, one

-keng wong

On Friday 15 June 2001 12:34 am, Jason van Zyl wrote:
> Try this:
>
> services.VelocityService.velocimacro.permissions.allow.inline.to.replace.gl
>o bal = true
>
> services.VelocityService.file.resource.loader.cache = false


---------------------------------------------------------------------
To unsubscribe, e-mail: turbine-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: turbine-user-help@jakarta.apache.org


Re: Are Macro libraries polled for changes?

Posted by Jason van Zyl <jv...@apache.org>.
On 6/15/01 1:05 AM, "psaunder@comcen.com.au" <ps...@comcen.com.au> wrote:

> Hello to all,
> I've noticed that if I make a change to a Velocity Macro
> library, that I have to restart Turbine for the changes to
> take effect. Is this correct, or I have I misconfigured
> something?
> It is a pain to have to restart every time something is
> modified.

Try this:
 
services.VelocityService.velocimacro.permissions.allow.inline.to.replace.glo
bal = true

services.VelocityService.file.resource.loader.cache = false

 
> Changes to layouts and screen templates are detected
> no problems.
> 
> Thanks,
> 
> Patrick
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: turbine-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: turbine-user-help@jakarta.apache.org

-- 

jvz.

http://tambora.zenplex.org
http://jakarta.apache.org/turbine
http://jakarta.apache.org/velocity
http://jakarta.apache.org/alexandria
http://jakarta.apache.org/commons



---------------------------------------------------------------------
To unsubscribe, e-mail: turbine-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: turbine-user-help@jakarta.apache.org