cluster-cache
cache service to share data across workers/master
cache
var cache = ;
keys
var cache;//assume the cache is in use as above cache; //to use the cache, we assume u've started the cluster2 with caching enabled, and you can select how cache manager should be run
Note that, we allow you to use caching w/o cluster2, if you want to enable caching from none cluster2 runtime, the feature could be enabled via:
//you can use this in unit test too as we did;
get
- with the loader, if concurrent
get
happens across the workers in a cluster, only one will be allowed to load while the rest will be in factwatch
till that one finishes loading. - this will reduce the stress upon the backend services which loads exact same data nicely
var cache; cache ;
set
var cache; cache ;
del
var cache; cache ;
watch
var cache; cache;
unwatch
var cache; cache;//stop watching