Forum: Ruby on Rails How can I stop view caching?

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-04 17:57
(Received via mailing list)
Does anybody know how to stop the caching for views?

I'm using Lighttpd with fcgi. Every time I make a change to the HTML in
a view, I have to restart lighttpd before I can see the result of the
change.  I understand that the page is is compiled until it sees the
modification date has changed. However, I am working on a Linux machine
and editing the files on a Samba mount from my Mac OS X workstation. It
doesn't look like the mod dates are being updated. So the result is a
caching problem.

Anybody have this problem? Know how to fix it?

Thanks,
Phill
Bc80625db60e9db4394c51d6c1892b49?d=identicon&s=25 Derrick Spell (Guest)
on 2006-04-05 15:30
(Received via mailing list)
If you are in running in an development environment, then page
caching should be disabled.  Are you sure it's not your browser doing
the caching?  Also, forgive me the obvious question, but why not do
all your development locally on your linux box, and move it to the
server when you've got it ready?

-Derrick
34f5b045aec62235c17458650ea75353?d=identicon&s=25 Steve Koppelman (hatless)
on 2006-04-05 15:48
Why are you doing development with FCGI? That makes it sound like you've
set things up to run in production mode, which has caching turned on by
default and would need to be turned off in
config/environment/production.rb  .... but really if this is the case
you should be developing in development mode, which has caching turned
off.

Second, as the last respondent noted, why are you editing a live
application on a remote file share? Wouldn't it be much easier to
develop directly on your OS X box with a less-elaborately configured
webserver that isn't running an application-caching container like FCGI?

It really sounds like you're running in production mode, which is pretty
hard to do by accident, but if you're certain you're in development mode
and this same thing happens when you use WEBrick instead of
lighttpd+fcgi, maybe it really is the timestamp issue on the files, in
which case you would need to consult Samba documentation. A
misconfigured fileserver is beyond the scope of a Rails list. ;)

Phillip Novess wrote:
> Does anybody know how to stop the caching for views?
>
> I'm using Lighttpd with fcgi. Every time I make a change to the HTML in
> a view, I have to restart lighttpd before I can see the result of the
> change.  I understand that the page is is compiled until it sees the
> modification date has changed. However, I am working on a Linux machine
> and editing the files on a Samba mount from my Mac OS X workstation. It
> doesn't look like the mod dates are being updated. So the result is a
> caching problem.
>
> Anybody have this problem? Know how to fix it?
>
> Thanks,
> Phill
This topic is locked and can not be replied to.