|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.gcube.opensearch.opensearchdatasource.cacherefresh.CacheRefresher
public class CacheRefresher
In charge of refreshing the generic resource caches contained in the state WS resources of the
OpenSearchDataSource
. After purging a cache, the top-level generic resource is retrieved
again from the IS and re-cached, ensuring that the service operates on up-to-date generic resources.
All cached description documents contained in the caches are also purged from the caches.
Depending on configuration, the refresh operation can be performed periodically on a configurable time interval in milliseconds.
If the time interval is equal to 0, no periodic refresh cycles are performed.
The cache can also be refreshed on demand, via the OpenSearchDataSource#refreshCache(org.gcube.opensearch.opensearchdatasource.stubs.RefreshCache)
operation
of its portType
Constructor Summary | |
---|---|
CacheRefresher(long refreshIntervalMillis)
Creates a new cache refresher |
Method Summary | |
---|---|
void |
forceRefresh()
Schedules a forced cache refresh to be performed as soon as possible The scheduled activation time of the next cache refresh cycle is not affected |
void |
run()
Performs the periodic and forced cache refresh operations |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public CacheRefresher(long refreshIntervalMillis)
refreshIntervalMillis
- The time interval between cache refresh cycles, in millisecondsMethod Detail |
---|
public void run()
run
in interface java.lang.Runnable
public void forceRefresh()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |