silverstripe/silverstripe-framework — pull request #3176 by patbolo (2014-05-30 04:39:45+00:00)
Title: MINOR Uses SS_Cache to cache RestfulService responses instead of filesys...

...tem

xmlresponse_* files are saved in the temp folder, are not garbage collected (they can fill up a disk if not actively monitored) and are not in line with the usual approach for managing cached objects in the framework. Using APC or similar other backend is then impossible for these files. This PR porposes to use SS_Cache for these files as well. Also the current code will use the cached object if available if the live call failed, the new code doesn't provide this fallback mechanism, but whether this fallback is a good thing is really debatable, as the returned cached object is stalled, and this error can be part of the spec for the API (ie 404 resource not found anymore)