[SPRNET-1489] Support invalidating cache at the entire method level Created: 23/Jan/12  Updated: 30/Apr/12  Resolved: 30/Apr/12

Status: Resolved
Project: Spring.NET
Component/s: Spring-NET-CORE
Affects Version/s: 1.3.2
Fix Version/s: 2.0 M1

Type: Improvement Priority: Minor
Reporter: Steve Bohlen Assignee: Steve Bohlen
Resolution: Won't Fix Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Reference URL: http://forum.springframework.net/showthread.php?9864-Invalidate-Cache-Key-with-parameter

 Description   

Consider support for invalidating the cache at the level of a single method scope rather than only specific to given set of params for the method (essentially support invalidating the entire method's cache regardless of params).



 Comments   
Comment by Steve Bohlen [ 18/Apr/12 ]

need to reconsider a way to accomplish this that isn't reliant on the 'magic string' value in the sample demonstrated in the code from the forum post

Comment by Steve Bohlen [ 30/Apr/12 ]

The approach recommended in the forum post (even if broadened to support more general use-cases than the very specific impl. shown tied to methodname string parsing) would require iterating over the keys in the collection in order to determine whether to evict them from the cache. With a local in-memory cache this might be an acceptable operation in re: performance concerns, but with any sort of distributed cache this would almost certainly introduce unacceptable performance characteristics (network round trip, serialize/deserialize every key to perform the comparison, etc.). As such, this suggestion to add this capability to the SPRNET Caching Advice is being declined at this time (since its essentially a query-across-the-whole-cache scenario and most distributed cache impls. are notoriously poor-performing at these sorts of opertations).

Generated at Fri Jul 19 10:24:43 UTC 2019 using JIRA 7.9.2#79002-sha1:3bb15b68ecd99a30eb364c4c1a393359bcad6278.