Data Expiration Strategies
NCache supports time-based data invalidation where you can specify the time or interval to expire your cache data. Time based data invalidation is used if changes to the data occur in a deterministic time fashion or where you can determine the frequency of data change.
Moreover, expiring stale data from the cache results in relevant and updated data being provided to the client. Expiring such data from the cache after a certain time period will result in fresh data being loaded into the cache on the next client request.
Another use of data expiration is in maintaining sessions. If a session has been inactive for a certain period of time, it can be removed from the cache as it is idle.
NCache supports Absolute and Sliding Expirations, along with an extended flexibility to use multiple default expirations on one dataset. These will be discussed in detail in successive topics.
In This Section
Data Expirations Overview
Explains use cases and behaviors for absolute expiration, sliding expiration and default expirations.
Absolute Expiration
Explains how to perform operations using Absolute Expiration.
Sliding Expiration
Explains how to perform operations using Sliding Expiration.