Reputation: 5689
Is it possible to declaratively configure the spring.net cache rather using attributes?
I dont want to add the attribute such as :
[CacheResult("AspNetCache", "'Airport.Id=' + #id", TimeToLive = "0:1:0")]
I'd rather do this in configuration files
Upvotes: 2
Views: 582
Reputation: 5101
It looks like spring.net doesn't support this yet. Quote from the documentation of the latest release (1.3rc1): "The aspect currently relies on using attributes to specify the pointcut as well as the behavior, much like the transactional aspect. Future versions will allow for external configuration of the behavior so you can apply caching to a code base without needing to use attributes in the code."
And there is a related issue in their Jira.
Upvotes: 2