Sync Cache with External Source
NCache provides the user with the facility to synchronize cache data by providing dependencies on other items in the cache or by providing dependency on items from one cache on items in another cache to keep the data integrity and scalability. NCache then further provides the ability to the user to add data in a cache which is dependent on any item or file placed outside the cache. This way cache data remains synced with the data present outside of the cache.
For example there is an item placed in the cache. It has a dependency on a file placed at an external location which means the file does not exist in the cache. The application needs the data of the cache synced with the file placed somewhere out of the cache. So whenever the file is modified or removed; the item dependent on the file will expire and eventually be removed on the next cleanup interval.
Moreover there are ways through which the user can implement their own custom logics for the validation of a certain data.
In this Section
Explains how to add data using file dependency.
Explains how the user can write his own dependency scenarios and use the feature of custom dependency.
Aggregate Cache Dependency
Explains how to add multiple dependencies with a single cache item.