updated servlet init
git-svn-id: http://svn.research-infrastructures.eu/public/d4science/gcube/trunk/data-transfer/uri-resolver@100706 82a268e6-3cf1-43bd-a215-b396298e98cf
This commit is contained in:
parent
775d559397
commit
bb0394a149
|
@ -67,9 +67,11 @@ public class GisResolver extends HttpServlet{
|
|||
private Timer timer;
|
||||
private GisViewerAppGenericResourcePropertyReader gisViewerAppPropertyReader;
|
||||
|
||||
//FIVE MINUTES
|
||||
//TEN MINUTES
|
||||
public static final long CACHE_RESET_TIME = 10*60*1000;
|
||||
|
||||
public static final long CACHE_RESET_DELAY = 5*1000;
|
||||
|
||||
@Override
|
||||
public void init() throws ServletException {
|
||||
super.init();
|
||||
|
@ -77,12 +79,12 @@ public class GisResolver extends HttpServlet{
|
|||
timer.schedule(new TimerTask() {
|
||||
@Override
|
||||
public void run() {
|
||||
logger.info("Timer resetting cache..");
|
||||
logger.info("Resetting cache...");
|
||||
reseCacheServerParameters();
|
||||
reseGisViewerAppEndPoint();
|
||||
reseCacheGisViewerApplicationHostname();
|
||||
}
|
||||
}, 0, CACHE_RESET_TIME);
|
||||
}, CACHE_RESET_DELAY, CACHE_RESET_TIME);
|
||||
}
|
||||
|
||||
protected ServerParameters getCachedServerParameters(String scope) throws Exception{
|
||||
|
|
Loading…
Reference in New Issue