You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tapestry.apache.org by Michael Gentry <mg...@masslight.net> on 2010/11/03 14:24:12 UTC

FAQ Entry? How to render TML from a database.

Would an entry on how to render TML from a database be worthwhile?
I've been pondering that off-and-on lately for one of our projects,
but haven't explored the details yet.

Thanks,

mrg

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
For additional commands, e-mail: users-help@tapestry.apache.org


Re: FAQ Entry? How to render TML from a database.

Posted by Bob Harner <bo...@gmail.com>.
Michael,

If the customer doesn't like the down time for small changes, it might be
beneficial to cluster the app, so you can update it without any down time.
That would probably be a lot easier/cheaper to set up than the major code
changes you're considering. Just a thought.
On Nov 4, 2010 9:06 AM, "Michael Gentry" <mg...@masslight.net> wrote:
> Hi Thiago,
>
> The biggest T5 project we have isn't really a CMS. We have data entry
> wizards (say, ~10 pages/wizard) that the user steps through. Each
> page is pretty much defined as far as navigation/data goes (and each
> one sits in a common layout), but our customer every now and then
> calls up and wants the wording/spacing/etc tweaked on a page. There
> is only so much CSS in a database can do for this scenario. In these
> cases we update the TML and redeploy the application and they don't
> like the downtime.
>
> So, that's the scenario behind my thoughts of having the TML in the
> database. For simple tweaks it might be nice. I realize there are
> other issues (have to expire the page pool, versioning control, etc).
> Just a thought I'm kicking around. :-)
>
> Thanks,
>
> mrg
>
>
> On Wed, Nov 3, 2010 at 12:38 PM, Thiago H. de Paula Figueiredo
> <th...@gmail.com> wrote:
>> I really don't think it's good idea to use Tapestry templates as a CMS
>> instead of using Tapestry to implement a CMS with some templating
language
>> meant to be used by non-programmers. I hope this isn't what Michael wants
.
>> . .
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
> For additional commands, e-mail: users-help@tapestry.apache.org
>

Re: FAQ Entry? How to render TML from a database.

Posted by Howard Lewis Ship <hl...@gmail.com>.
On Fri, Nov 5, 2010 at 5:15 AM, Michael Gentry <mg...@masslight.net>wrote:

> Thanks for pointing that out, Howard.  I was looking at the code a bit
> on GitHub (don't know if that is current).  The JavaDoc seems to imply
> it allows access to properties, assets, messages, but maybe not other
> TML items?  For example, does it support t:loop, t:if, t:textfield,
> etc?
>
>
It effectively re-implements template expansions inside the dynamic
template, allowing them to work in a dynamic template as they would in the
main Tapestry template.

t:if, t:loop, etc. are components; it does not re-implement components!
 However, you can pass components inside blocks (i.e., using the
<p:blockName> structure) and reference those blocks inside the dynamic
template.

It's all about mating a very dynamic template to the statically structured
(but randomly accessible) structure of a Tapestry page.



> Thanks,
>
> mrg
>
>
> On Thu, Nov 4, 2010 at 11:32 AM, Howard Lewis Ship <hl...@gmail.com>
> wrote:
> > Yes, there's no documentation (yet), but what you are trying to do can be
> > accomplished with the tapx/Dynamic component (part of tapx-core).
> >
> > Alas, you'll need to build it yourself (using Gradle, so it's easy) since
> I
> > haven't updated the tapestry360 Bamboo for Gradle, so no nightly builds.
> >
> > On Thu, Nov 4, 2010 at 7:28 AM, Michael Gentry <mgentry@masslight.net
> >wrote:
> >
> >> On Thu, Nov 4, 2010 at 10:21 AM, Thiago H. de Paula Figueiredo
> >> <th...@gmail.com> wrote:
> >> > On Thu, 04 Nov 2010 12:05:25 -0200, Michael Gentry <
> >> mgentry@masslight.net>
> >> > wrote:
> >> >
> >> >> I believe running exploded is against the security regulations here.
> >> >
> >> > Why?
> >>
> >>
> >> That is a long story to answer, but let's just say they have security
> >> guidelines they (the production support team) follow.
> >>
> >>
> >> >> Also, wouldn't you have to turn production mode off for Tapestry to
> >> >> pick up changes to the TML?
> >> >
> >> > Absolutely no. Tapestry picks up changes (aka live class reloading) in
> >> > templates, property files and component, page and mixin classes in
> >> > production mode too. Production mode, as far as I can remember,
> affects
> >> just
> >> > the default error page and some configuration symbols.
> >>
> >>
> >> I did not realize that.  I guess coming from a WebObjects background,
> >> I expected production mode to turn off the template reloading feature
> >> to improve performance (no scanning for changes, for example).  I've
> >> learned something new today.  :-)
> >>
> >> Thanks,
> >>
> >> mrg
> >>
> >> ---------------------------------------------------------------------
> >> To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
> >> For additional commands, e-mail: users-help@tapestry.apache.org
> >>
> >>
> >
> >
> > --
> > Howard M. Lewis Ship
> >
> > Creator of Apache Tapestry
> >
> > The source for Tapestry training, mentoring and support. Contact me to
> learn
> > how I can get you up and productive in Tapestry fast!
> >
> > (971) 678-5210
> > http://howardlewisship.com
> >
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
> For additional commands, e-mail: users-help@tapestry.apache.org
>
>


-- 
Howard M. Lewis Ship

Creator of Apache Tapestry

The source for Tapestry training, mentoring and support. Contact me to learn
how I can get you up and productive in Tapestry fast!

(971) 678-5210
http://howardlewisship.com

Re: FAQ Entry? How to render TML from a database.

Posted by Michael Gentry <mg...@masslight.net>.
Thanks for pointing that out, Howard.  I was looking at the code a bit
on GitHub (don't know if that is current).  The JavaDoc seems to imply
it allows access to properties, assets, messages, but maybe not other
TML items?  For example, does it support t:loop, t:if, t:textfield,
etc?

Thanks,

mrg


On Thu, Nov 4, 2010 at 11:32 AM, Howard Lewis Ship <hl...@gmail.com> wrote:
> Yes, there's no documentation (yet), but what you are trying to do can be
> accomplished with the tapx/Dynamic component (part of tapx-core).
>
> Alas, you'll need to build it yourself (using Gradle, so it's easy) since I
> haven't updated the tapestry360 Bamboo for Gradle, so no nightly builds.
>
> On Thu, Nov 4, 2010 at 7:28 AM, Michael Gentry <mg...@masslight.net>wrote:
>
>> On Thu, Nov 4, 2010 at 10:21 AM, Thiago H. de Paula Figueiredo
>> <th...@gmail.com> wrote:
>> > On Thu, 04 Nov 2010 12:05:25 -0200, Michael Gentry <
>> mgentry@masslight.net>
>> > wrote:
>> >
>> >> I believe running exploded is against the security regulations here.
>> >
>> > Why?
>>
>>
>> That is a long story to answer, but let's just say they have security
>> guidelines they (the production support team) follow.
>>
>>
>> >> Also, wouldn't you have to turn production mode off for Tapestry to
>> >> pick up changes to the TML?
>> >
>> > Absolutely no. Tapestry picks up changes (aka live class reloading) in
>> > templates, property files and component, page and mixin classes in
>> > production mode too. Production mode, as far as I can remember, affects
>> just
>> > the default error page and some configuration symbols.
>>
>>
>> I did not realize that.  I guess coming from a WebObjects background,
>> I expected production mode to turn off the template reloading feature
>> to improve performance (no scanning for changes, for example).  I've
>> learned something new today.  :-)
>>
>> Thanks,
>>
>> mrg
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
>> For additional commands, e-mail: users-help@tapestry.apache.org
>>
>>
>
>
> --
> Howard M. Lewis Ship
>
> Creator of Apache Tapestry
>
> The source for Tapestry training, mentoring and support. Contact me to learn
> how I can get you up and productive in Tapestry fast!
>
> (971) 678-5210
> http://howardlewisship.com
>

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
For additional commands, e-mail: users-help@tapestry.apache.org


Re: FAQ Entry? How to render TML from a database.

Posted by Howard Lewis Ship <hl...@gmail.com>.
Yes, there's no documentation (yet), but what you are trying to do can be
accomplished with the tapx/Dynamic component (part of tapx-core).

Alas, you'll need to build it yourself (using Gradle, so it's easy) since I
haven't updated the tapestry360 Bamboo for Gradle, so no nightly builds.

On Thu, Nov 4, 2010 at 7:28 AM, Michael Gentry <mg...@masslight.net>wrote:

> On Thu, Nov 4, 2010 at 10:21 AM, Thiago H. de Paula Figueiredo
> <th...@gmail.com> wrote:
> > On Thu, 04 Nov 2010 12:05:25 -0200, Michael Gentry <
> mgentry@masslight.net>
> > wrote:
> >
> >> I believe running exploded is against the security regulations here.
> >
> > Why?
>
>
> That is a long story to answer, but let's just say they have security
> guidelines they (the production support team) follow.
>
>
> >> Also, wouldn't you have to turn production mode off for Tapestry to
> >> pick up changes to the TML?
> >
> > Absolutely no. Tapestry picks up changes (aka live class reloading) in
> > templates, property files and component, page and mixin classes in
> > production mode too. Production mode, as far as I can remember, affects
> just
> > the default error page and some configuration symbols.
>
>
> I did not realize that.  I guess coming from a WebObjects background,
> I expected production mode to turn off the template reloading feature
> to improve performance (no scanning for changes, for example).  I've
> learned something new today.  :-)
>
> Thanks,
>
> mrg
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
> For additional commands, e-mail: users-help@tapestry.apache.org
>
>


-- 
Howard M. Lewis Ship

Creator of Apache Tapestry

The source for Tapestry training, mentoring and support. Contact me to learn
how I can get you up and productive in Tapestry fast!

(971) 678-5210
http://howardlewisship.com

Re: FAQ Entry? How to render TML from a database.

Posted by Michael Gentry <mg...@masslight.net>.
On Thu, Nov 4, 2010 at 10:21 AM, Thiago H. de Paula Figueiredo
<th...@gmail.com> wrote:
> On Thu, 04 Nov 2010 12:05:25 -0200, Michael Gentry <mg...@masslight.net>
> wrote:
>
>> I believe running exploded is against the security regulations here.
>
> Why?


That is a long story to answer, but let's just say they have security
guidelines they (the production support team) follow.


>> Also, wouldn't you have to turn production mode off for Tapestry to
>> pick up changes to the TML?
>
> Absolutely no. Tapestry picks up changes (aka live class reloading) in
> templates, property files and component, page and mixin classes in
> production mode too. Production mode, as far as I can remember, affects just
> the default error page and some configuration symbols.


I did not realize that.  I guess coming from a WebObjects background,
I expected production mode to turn off the template reloading feature
to improve performance (no scanning for changes, for example).  I've
learned something new today.  :-)

Thanks,

mrg

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
For additional commands, e-mail: users-help@tapestry.apache.org


Re: FAQ Entry? How to render TML from a database.

Posted by "Thiago H. de Paula Figueiredo" <th...@gmail.com>.
On Thu, 04 Nov 2010 12:05:25 -0200, Michael Gentry <mg...@masslight.net>  
wrote:

> I believe running exploded is against the security regulations here.

Why?

> Also, wouldn't you have to turn production mode off for Tapestry to
> pick up changes to the TML?

Absolutely no. Tapestry picks up changes (aka live class reloading) in  
templates, property files and component, page and mixin classes in  
production mode too. Production mode, as far as I can remember, affects  
just the default error page and some configuration symbols.

-- 
Thiago H. de Paula Figueiredo
Independent Java, Apache Tapestry 5 and Hibernate consultant, developer,  
and instructor
Owner, Ars Machina Tecnologia da Informação Ltda.
http://www.arsmachina.com.br

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
For additional commands, e-mail: users-help@tapestry.apache.org


Re: FAQ Entry? How to render TML from a database.

Posted by Michael Gentry <mg...@masslight.net>.
I believe running exploded is against the security regulations here.
Also, wouldn't you have to turn production mode off for Tapestry to
pick up changes to the TML?

Thanks again,

mrg


On Thu, Nov 4, 2010 at 9:28 AM, Thiago H. de Paula Figueiredo
<th...@gmail.com> wrote:
> Why don't you just replace the .tml in the server? Can't you use an exploded
> WAR in production?
>

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
For additional commands, e-mail: users-help@tapestry.apache.org


Re: FAQ Entry? How to render TML from a database.

Posted by "Thiago H. de Paula Figueiredo" <th...@gmail.com>.
On Thu, 04 Nov 2010 11:05:36 -0200, Michael Gentry <mg...@masslight.net>  
wrote:

> Hi Thiago,

Hi, Michael!

> The biggest T5 project we have isn't really a CMS.  We have data entry
> wizards (say, ~10 pages/wizard) that the user steps through.  Each
> page is pretty much defined as far as navigation/data goes (and each
> one sits in a common layout), but our customer every now and then
> calls up and wants the wording/spacing/etc tweaked on a page.  There
> is only so much CSS in a database can do for this scenario.  In these
> cases we update the TML and redeploy the application and they don't
> like the downtime.

Why don't you just replace the .tml in the server? Can't you use an  
exploded WAR in production?

-- 
Thiago H. de Paula Figueiredo
Independent Java, Apache Tapestry 5 and Hibernate consultant, developer,  
and instructor
Owner, Ars Machina Tecnologia da Informação Ltda.
http://www.arsmachina.com.br

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
For additional commands, e-mail: users-help@tapestry.apache.org


Re: FAQ Entry? How to render TML from a database.

Posted by Michael Gentry <mg...@masslight.net>.
Hi Thiago,

The biggest T5 project we have isn't really a CMS.  We have data entry
wizards (say, ~10 pages/wizard) that the user steps through.  Each
page is pretty much defined as far as navigation/data goes (and each
one sits in a common layout), but our customer every now and then
calls up and wants the wording/spacing/etc tweaked on a page.  There
is only so much CSS in a database can do for this scenario.  In these
cases we update the TML and redeploy the application and they don't
like the downtime.

So, that's the scenario behind my thoughts of having the TML in the
database.  For simple tweaks it might be nice.  I realize there are
other issues (have to expire the page pool, versioning control, etc).
Just a thought I'm kicking around.  :-)

Thanks,

mrg


On Wed, Nov 3, 2010 at 12:38 PM, Thiago H. de Paula Figueiredo
<th...@gmail.com> wrote:
> I really don't think it's good idea to use Tapestry templates as a CMS
> instead of using Tapestry to implement a CMS with some templating language
> meant to be used by non-programmers. I hope this isn't what Michael wants .
> . .

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
For additional commands, e-mail: users-help@tapestry.apache.org


Re: FAQ Entry? How to render TML from a database.

Posted by "Thiago H. de Paula Figueiredo" <th...@gmail.com>.
I really don't think it's good idea to use Tapestry templates as a CMS  
instead of using Tapestry to implement a CMS with some templating language  
meant to be used by non-programmers. I hope this isn't what Michael wants  
. . .

On Wed, 03 Nov 2010 14:35:52 -0200, Howard Lewis Ship <hl...@gmail.com>  
wrote:

> That seems like more of a cookbook item.
>
> On Wed, Nov 3, 2010 at 6:24 AM, Michael Gentry  
> <mg...@masslight.net>wrote:
>
>> Would an entry on how to render TML from a database be worthwhile?
>> I've been pondering that off-and-on lately for one of our projects,
>> but haven't explored the details yet.
>>
>> Thanks,
>>
>> mrg
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
>> For additional commands, e-mail: users-help@tapestry.apache.org
>>
>>
>
>


-- 
Thiago H. de Paula Figueiredo
Independent Java, Apache Tapestry 5 and Hibernate consultant, developer,  
and instructor
Owner, Ars Machina Tecnologia da Informação Ltda.
Consultor, desenvolvedor e instrutor em Java, Tapestry e Hibernate
Coordenador e professor da Especialização em Engenharia de Software com  
Ênfase em Java da Faculdade Pitágoras
http://www.arsmachina.com.br

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
For additional commands, e-mail: users-help@tapestry.apache.org


Re: FAQ Entry? How to render TML from a database.

Posted by Howard Lewis Ship <hl...@gmail.com>.
That seems like more of a cookbook item.

On Wed, Nov 3, 2010 at 6:24 AM, Michael Gentry <mg...@masslight.net>wrote:

> Would an entry on how to render TML from a database be worthwhile?
> I've been pondering that off-and-on lately for one of our projects,
> but haven't explored the details yet.
>
> Thanks,
>
> mrg
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
> For additional commands, e-mail: users-help@tapestry.apache.org
>
>


-- 
Howard M. Lewis Ship

Creator of Apache Tapestry

The source for Tapestry training, mentoring and support. Contact me to learn
how I can get you up and productive in Tapestry fast!

(971) 678-5210
http://howardlewisship.com