On Sat, Jan 9, 2010 at 9:08 AM, greekscala <[email protected]> wrote:
> Like, makes it sense to cache a fragment xml when building a list so I > dont have to call findAnyTemplate all the time....? > Keep in mind that in production mode, Lift caches templates so findAnyTemplate is a hash table lookup as long as your template is in cache. > > On 9 Jan., 17:31, greekscala <[email protected]> wrote: > > Hello Marius, > > > > yes it is more intended for caching. Ok so I can remove this vals from > > my code. > > Any other simple performance rules that one should be aware of for > > Lift? > > > > witth best regards > > > > On 9 Jan., 16:38, Marius <[email protected]> wrote: > > > > > Are you using vals mainly for the purpose of caching ? > > > > > I think it is ok to call findAnyTemplates (without using vals) as > > > templates are cached (in production mode) > > > > > Br's, > > > Marius > > > > > On Jan 9, 5:29 pm, greekscala <[email protected]> wrote: > > > > > > Hello everyone, > > > > > > I am surprised about the few code I have written and the effect I > > > > get :) > > > > > > I would like to know if this workflow can be optimized: > > > > > > I my snippet method I "findAnyTemplate()" my xml fragments and > > > > assigning them > > > > to vals. > > > > > > Then I have little functions that bind content with the above xml > > > > fragments and return > > > > the resulting NodeSeq, so I can do easy an SetHtml and return the new > > > > content with > > > > ajax. > > > > > > I find this way very easy. So I can have many little fragments, load > > > > them bind content > > > > and return them via ajax. > > > > > > Is it ok to load the fragments and save them in vals? Or can I do a > > > > findAnyTemplate() > > > > all the time? Or should I have snippets methods for this fragments > and > > > > let lift do the > > > > snippet method calling? > > > > > > with best regards > > -- > You received this message because you are subscribed to the Google Groups > "Lift" group. > To post to this group, send email to [email protected]. > To unsubscribe from this group, send email to > [email protected]<liftweb%[email protected]> > . > For more options, visit this group at > http://groups.google.com/group/liftweb?hl=en. > > > > -- Lift, the simply functional web framework http://liftweb.net Beginning Scala http://www.apress.com/book/view/1430219890 Follow me: http://twitter.com/dpp Surf the harmonics--
You received this message because you are subscribed to the Google Groups "Lift" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to [email protected].
For more options, visit this group at http://groups.google.com/group/liftweb?hl=en.
