Forum: Ruby on Rails Is there anyway to make Rails NOT cache?

Announcement (2017-05-07): www.ruby-forum.com is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see rubyonrails.org/community and ruby-lang.org/en/community for other Rails- und Ruby-related community platforms.
6a657bbaaa704aa1fc7dfa6d680c06fc?d=identicon&s=25 Phillip Novess (Guest)
on 2006-04-17 21:56
(Received via mailing list)
Is there anyway to make Rails NOT cache?  I'm getting caching in the
browser and the server.

I have to restart Lighttpd after every view change to see the results.

Thanks,
phill
Fb23bc8cd4030c526b0689276b34c8bd?d=identicon&s=25 Bryan Duxbury (bryanduxbury)
on 2006-04-17 22:00
Phillip Novess wrote:
> Is there anyway to make Rails NOT cache?  I'm getting caching in the
> browser and the server.
>
> I have to restart Lighttpd after every view change to see the results.
>
> Thanks,
> phill

Are you doing development at this point? If so, you really don't want to
be using lighttpd - good old webrick will do the trick.

If script\server is running lighttpd and causing trouble, do
"script\server webrick" instead.
Cf7e5e4b5ca573eec214191fac420a2f?d=identicon&s=25 Dave Silvester (Guest)
on 2006-04-17 22:12
(Received via mailing list)
On Monday 17 Apr 2006 21:00, Bryan Duxbury wrote:
> Are you doing development at this point? If so, you really don't want to
> be using lighttpd - good old webrick will do the trick.

I'm developing using Lighttpd and it's great - no caching problem at
all.
Can't say I ever noticed one?

Surely it can't be the default behaviour, otherwise why would support
for it
have been added if it was unusable because of caching issues?  Sounds
like
the culprit might be something else (eg. wrong configuration settings)
to me.

> If script\server is running lighttpd and causing trouble, do
> "script\server webrick" instead.

Though webrick does indeed do the job perfectly OK for development
purposes.

~Dave

--

Dave Silvester
Rent-A-Monkey Website Development
http://www.rentamonkey.com/

PGP Key: http://www.rentamonkey.com/pgpkey.asc
Fb23bc8cd4030c526b0689276b34c8bd?d=identicon&s=25 Bryan Duxbury (bryanduxbury)
on 2006-04-17 22:19
Dave Silvester wrote:
> Surely it can't be the default behaviour, otherwise why would support
> for it
> have been added if it was unusable because of caching issues?  Sounds
> like
> the culprit might be something else (eg. wrong configuration settings)
> to me.

Oh yeah - make sure you're not in production mode. That would certainly
cause problems.
Ce8b03e5750097942c58e12b46724312?d=identicon&s=25 Giles Bowkett (Guest)
on 2006-04-17 22:22
(Received via mailing list)
There's stuff abt this in the Agile book, and IIRC it's pretty
flexible/powerful, but I don't recall the specifics off the top of my
head (sorry). Google it with site:api.rubyonrails.com in the search,
tho, because it's definitely in there.

Giles



On 4/17/06, Dave Silvester <dave@rentamonkey.com> wrote:
> me.
> Dave Silvester
> Rent-A-Monkey Website Development
> http://www.rentamonkey.com/
>
> PGP Key: http://www.rentamonkey.com/pgpkey.asc
> _______________________________________________
> Rails mailing list
> Rails@lists.rubyonrails.org
> http://lists.rubyonrails.org/mailman/listinfo/rails
>


--
Giles Bowkett
http://www.gilesgoatboy.org
6a657bbaaa704aa1fc7dfa6d680c06fc?d=identicon&s=25 Phillip Novess (Guest)
on 2006-04-18 00:19
(Received via mailing list)
Thanks for all the responses.

I believe I'm in development mode.  At least the lighttpd.conf file has
the RAILS_ENV set to development.

The cache of the views I know was mentioned in the docs. I remember
something about the mod time is compared to render time to determine
whether it should be compiled.  However, I believe that when I edit
files via Samba on my Mac the mod time is n't updated correctly and
thus never gets recompiled until I restart.

The other caching problem is the cache in my browser.  In PHP I use to
set the headers for no-pragma cache.   How do you do this in Rails? My
browser is definitely caching.

Thanks,
phill



On Apr 17, 2006, at 2:21 PM, Giles Bowkett wrote:

There's stuff abt this in the Agile book, and IIRC it's pretty
flexible/powerful, but I don't recall the specifics off the top of my
head (sorry). Google it with site:api.rubyonrails.com in the search,
tho, because it's definitely in there.

Giles



On 4/17/06, Dave Silvester <dave@rentamonkey.com> wrote:
> for it
> purposes.
> _______________________________________________
> Rails mailing list
> Rails@lists.rubyonrails.org
> http://lists.rubyonrails.org/mailman/listinfo/rails
>


--
Giles Bowkett
http://www.gilesgoatboy.org
_______________________________________________
Rails mailing list
Rails@lists.rubyonrails.org
http://lists.rubyonrails.org/mailman/listinfo/rails
34f5b045aec62235c17458650ea75353?d=identicon&s=25 Steve Koppelman (hatless)
on 2006-04-18 01:09
If your Samba server is misconfigured and not updating timestamps on
files, then fix the configuration of your Samba server.

Or better yet, don't develop by editing files on a remote fileshare. ;)

Phillip Novess wrote:
> Thanks for all the responses.
>
> I believe I'm in development mode.  At least the lighttpd.conf file has
> the RAILS_ENV set to development.
>
> The cache of the views I know was mentioned in the docs. I remember
> something about the mod time is compared to render time to determine
> whether it should be compiled.  However, I believe that when I edit
> files via Samba on my Mac the mod time is n't updated correctly and
> thus never gets recompiled until I restart.
>
> The other caching problem is the cache in my browser.  In PHP I use to
> set the headers for no-pragma cache.   How do you do this in Rails? My
> browser is definitely caching.
>
> Thanks,
> phill
>
>
>
> On Apr 17, 2006, at 2:21 PM, Giles Bowkett wrote:
>
> There's stuff abt this in the Agile book, and IIRC it's pretty
> flexible/powerful, but I don't recall the specifics off the top of my
> head (sorry). Google it with site:api.rubyonrails.com in the search,
> tho, because it's definitely in there.
>
> Giles
>
This topic is locked and can not be replied to.