[Catalyst] Page fragment caching

2010-01-20 Thread Tobias Kremer
Hey all, I have this CMS which generates static content into a Catalyst application. Because there is dynamic stuff like Most recent stories on almost every page, I'm rendering TT code into the content generated by the CMS and the final page is then eval'd by the main Catalyst TT view. (It's

Re: [Catalyst] uri_for

2010-01-20 Thread Carl Johnstone
Tomohiro Hosaka wrote: Is this correct result? Yes, the previous situation was a bug. Given sub foo : Args(1) { my ($c, $arg) = @_; }; The URL http://127.0.0.1/foo/bar%2Fbaz would match and set $arg to 'bar/baz' correctly. However reversing that using uri_for then returns the incorrect

Re: [Catalyst] Page fragment caching

2010-01-20 Thread Mike Whitaker
b) there is something like page fragment caching which allows me to not cache DBIC objects but generated HTML in an elegant way (without having to wrap each TT code snippet with cache get/set calls)? Catalyst::Plugin::PageCache only allows the caching of whole pages which currently is not an

Re: [Catalyst] Page fragment caching

2010-01-20 Thread Carl Johnstone
Tobias Kremer wrote: c) somebody smarter than me has a better idea how to solve this problem? :) Use Varnish as a caching-proxy in front-of your app. Use ESI to include the fragments and set appropiate cache-control headers in those reponses so Varnish can cache appropiately. Carl

Re: [Catalyst] Page fragment caching

2010-01-20 Thread Tobias Kremer
On Wed, Jan 20, 2010 at 10:43 AM, Carl Johnstone catal...@fadetoblack.me.uk wrote: Use Varnish as a caching-proxy in front-of your app. Use ESI to include the fragments and set appropiate cache-control headers in those reponses so Varnish can cache appropiately. Thanks! Unfortunately I don't

Re: [Catalyst] Page fragment caching

2010-01-20 Thread Peter Karman
Tobias Kremer wrote on 01/20/2010 03:51 AM: Any other ideas? Template::Plugin::Cache ? -- Peter Karman . http://peknet.com/ . pe...@peknet.com ___ List: Catalyst@lists.scsys.co.uk Listinfo:

Re: [Catalyst] Catalyst::Plugin::SubRequest default %params

2010-01-20 Thread Pavel O. Karoukin
Started using Catalyst::Pluign::SubRequest but found one annoying issue - by default it doesn't duplicate $c-req-params.I.e. each time I need to request some block for page I have to use subinclude('path/to/action', {}, c.reg.params) instead plain subinclude('path/to/action'); Is it only

Re: [Catalyst] Error handling

2010-01-20 Thread Wes Cravens
J. Shirley wrote: That will show you the errors, and I believe get you what you expect to see. Having said all that, I am fond of ErrorCatcher, and use its included Email emitter quite happily. I am currently attempting to use ErrorCatcher to send email but also have a custom error page be

Re: [Catalyst] Error handling

2010-01-20 Thread J. Shirley
On Wed, Jan 20, 2010 at 10:52 AM, Wes Cravens wcrav...@cortex-it.com wrote: J. Shirley wrote: That will show you the errors, and I believe get you what you expect to see.  Having said all that, I am fond of ErrorCatcher, and use its included Email emitter quite happily. I am currently

Re: [Catalyst] Page fragment caching

2010-01-20 Thread Tomas Doran
On 20 Jan 2010, at 09:37, Tobias Kremer wrote: b) there is something like page fragment caching which allows me to not cache DBIC objects but generated HTML in an elegant way (without having to wrap each TT code snippet with cache get/set calls)? As noted by already, serving ESI is a good way

Re: [Catalyst] Catalyst::Plugin::SubRequest default %params

2010-01-20 Thread Tomas Doran
On 20 Jan 2010, at 01:55, Pavel O. Karoukin wrote: Is it only me who think that SubRequest should include current request params by default and may be it was done this way by some intent I am missing? Yes it is just you :) However nothing is stopping you writing: around subrequest = sub

Re: [Catalyst] Error handling

2010-01-20 Thread Bill Moseley
On Mon, Jan 18, 2010 at 9:05 AM, Steve Kleiman st...@prodhub.com wrote: Thanks for all the feedback on how to log from within a schema. Log4perl is my hero. I'm still looking for a way to capture runtime errors and ideally email them out in addition to logging to a file. I use log4perl to

[Catalyst] [PATCH] C-P-UploadProgress (converted away from NEXT)

2010-01-20 Thread Toby Corkindale
Hey Andy, and general Catalyst guys. Attached is a patch to convert Catalyst::Plugin::UploadProgress into using Moose::Role instead of NEXT, since the latter is deprecated as of Cat-Runtime .18. Could you have a look over it? I'm not 100% sure the first function is good since it's never