History | Log In     View a printable version of the current page.  
Issue Details (XML | Word | Printable)

Key: CACHE-272
Type: Improvement Improvement
Status: Closed Closed
Resolution: Fixed
Priority: Major Major
Assignee: Lars Torunski
Reporter: Fabrizio Zellini
Votes: 0
Watchers: 1
Operations

If you were logged in you would be able to see more operations.
OSCache

Allow disabling of cacheing special http methods (e.g. POST/DELETE/PUT) in CacheFilter

Created: 16/Nov/06 06:00 AM   Updated: 19/Mar/07 05:53 PM
Component/s: Filters
Affects Version/s: 2.3.2
Fix Version/s: 2.4


 Description  « Hide
From the http specifications:

Some HTTP methods MUST cause a cache to invalidate an entity. This is either the entity referred to by the >Request-URI, or by the Location or Content-Location headers (if present). These methods are:

- PUT
- DELETE
- POST

so an URI called by this methods cannot be cached

 All   Comments   Change History      Sort Order:
Lars Torunski - [17/Nov/06 12:56 AM ]
Fabrizio, can you give us more details about the spec, e.g. chapter?

Fabrizio Zellini - [17/Nov/06 01:39 AM ]
Sure,

http://www.ietf.org/rfc/rfc2616.txt
chapter 13,page 97

Regards,Fabrizio



Lars Torunski - [19/Nov/06 07:14 AM ]
Fabrizio, currently I want to close this issue as a Won't Fix. Because
1) it is a MUST and not a HAVE TO
2) a developer can cache a page based on PUT or POST with special ICacheKeyProvider implementation; therefore the CacheFilter::isCacheable method should be backward compatible
3) you can reimplement the isCacheable method with your improvement request

Fabrizio Zellini - [19/Nov/06 12:11 PM ]
I have already reimplemented the isCacheable method,in order to use the filter in my rest-style web services,but I think would be better to make this behavior configurable by a filter parameter that, if missing, leaves the behavior unaltered, to complain your 2) .

e.g. parameter name=disableCacheOnMethods , parameter value=list of comma separated method names e.g. "POST,PUT,DELETE"

An improvement instead of a bug ?

Regard


Lars Torunski - [20/Nov/06 12:33 AM ]
Feel free to attach your changes here.

Lars Torunski - [18/Mar/07 09:23 AM ]
fixed in SVN rev. 428