Thin forcing page caching: should be configurable
Reported by science | April 2nd, 2008 @ 03:24 PM | in 0.8.0
Thin is hard coded to require page caching. Mongrel doesn't do this, so thin is incompatible with some configurations of existing mongrel installations.
I'd like to propose that thin have an optional configuration setting to make it not conduct page caching. Existing installations will be unaffected b/c this would be an optional setting.
The attached lines of code are where I believe the issue is occurring:
http://pastie.textmate.org/private/mdzbkpykitysl2xl4lwzcw
If there is a thin config file, perhaps we could set "page_caching: [true|false]" with the default (when not present) being true?
Changing this line:
elsif file_exist?(cached_path)
to something like:
elsif CONFIG[:page_caching] && file_exist?(cached_path)
This would also help speed up installations a bit where page caching is not required of thin, because the system would not be looking to disk for the cached files, when page caching is disabled.
Hope this helps - drop me a line if I can assist in implementation or explain why this is an important change.
Sincerely - S
Comments and changes to this ticket
-
macournoyer April 2nd, 2008 @ 03:31 PM
- Milestone set to 0.8.0
- State changed from new to open
Mongrel does have page caching activated all the time, but it's only for GET and HEAD request, which is the issue in this case.
I'll fix the Rails adapter in THin to only serve the page cache on GET or HEAD request.
thx for reporting!
-
macournoyer April 2nd, 2008 @ 08:50 PM
- State changed from open to resolved
fixed in http://github.com/macournoyer/th...
Please Sign in or create a free account to add a new ticket.
With your very own profile, you can contribute to projects, track your activity, watch tickets, receive and update tickets through your email and much more.
Create your profile
Help contribute to this project by taking a few moments to create your personal profile. Create your profile ยป