mirror of
https://github.com/DSpace/dspace-angular.git
synced 2025-10-08 10:34:15 +00:00
Add "debug" config and "allowStale" configs
This commit is contained in:
@@ -11,12 +11,16 @@ export interface CacheConfig extends Config {
|
||||
// In-memory caches of server-side rendered (SSR) content. These caches can be used to limit the frequency
|
||||
// of re-generating SSR pages to improve performance.
|
||||
serverSide: {
|
||||
// Debug server-side caching. Set to true to see cache hits/misses/refreshes in console logs.
|
||||
debug: boolean,
|
||||
// Cache specific to known bots. Allows you to serve cached contents to bots only.
|
||||
botCache: {
|
||||
// Maximum number of pages (rendered via SSR) to cache. Setting max=0 disables the cache.
|
||||
max: number;
|
||||
// Amount of time after which cached pages are considered stale (in ms)
|
||||
timeToLive: number;
|
||||
// true = return page from cache after timeToLive expires. false = return a fresh page after timeToLive expires
|
||||
allowStale: boolean;
|
||||
},
|
||||
// Cache specific to anonymous users. Allows you to serve cached content to non-authenticated users.
|
||||
anonymousCache: {
|
||||
@@ -24,6 +28,8 @@ export interface CacheConfig extends Config {
|
||||
max: number;
|
||||
// Amount of time after which cached pages are considered stale (in ms)
|
||||
timeToLive: number;
|
||||
// true = return page from cache after timeToLive expires. false = return a fresh page after timeToLive expires
|
||||
allowStale: boolean;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user