-
1. Re: Using pre-configured CacheLoader
belaban Apr 7, 2005 2:24 AM (in response to akropp)I changed this in CVS head: here's the new method (called in startService()):
protected void createCacheLoader() throws Exception {
if(cache_loader == null && cache_loader_class != null) {
Class cl=Thread.currentThread().getContextClassLoader().loadClass(cache_loader_class);
cache_loader=(CacheLoader)cl.newInstance();
}
cache_loader.setConfig(cache_loader_config);
cache_loader.setCache(this);
cache_loader.create();
cache_loader.start();
} -
2. Re: Using pre-configured CacheLoader
akropp Apr 7, 2005 8:39 AM (in response to akropp)That will do it. Thanks.
-
3. Re: Using pre-configured CacheLoader
belaban Apr 7, 2005 9:10 AM (in response to akropp)Actually, do another cvs update, because that code caused an NPE, the real code is:
protected void createCacheLoader() throws Exception {
if(cache_loader == null && cache_loader_class != null) {
Class cl=Thread.currentThread().getContextClassLoader().loadClass(cache_loader_class);
cache_loader=(CacheLoader)cl.newInstance();
}
if(cache_loader != null) {
cache_loader.setConfig(cache_loader_config);
cache_loader.setCache(this);
cache_loader.create();
cache_loader.start();
}
}