[Catalyst] Caching problem?

Matt S Trout dbix-class at trout.me.uk
Wed Jan 11 21:33:10 CET 2006


On Wed, Jan 11, 2006 at 01:32:53PM -0600, Brandon Black wrote:
> On 1/11/06, Wade.Stuart at fallon.com <Wade.Stuart at fallon.com> wrote:
> >
> > I have found that this ( http://www.perlmonks.org/index.pl?node_id=239698 )
> > post has a really good coverage on all browsers I have ever tested. Some
> > ignore no-cache some ignore it in Pragma but this seems to cover all bases.
> >
> > Just format the header like below,  but include all of the tags.
> >
> > -Wade
> >
> 
> I've encapsulated this into a Catalyst::Plugin::Response::NoCache,
> which when loaded as a plugin makes the following method available:
> 
> $c->res->no_cache;
> 
> Which sets all the headers mentioned in that PM node (+ max_age on the
> Cache-Control line).
> 
> I'll wrap it up like a proper module with docs and a Makefile and all
> that later tonight for publishing.

So long as you do it by setting MyApp->response_class and not by messing
with Catalyst::Response directly :)

-- 
     Matt S Trout       Offering custom development, consultancy and support
  Technical Director    contracts for Catalyst, DBIx::Class and BAST. Contact
Shadowcat Systems Ltd.  mst (at) shadowcatsystems.co.uk for more information

 + Help us build a better perl ORM: http://dbix-class.shadowcatsystems.co.uk/ +



More information about the Catalyst mailing list