// refresh the resource by calling LDClient
log.debug("refreshing resource {}",resource);
this.lock.readLock().lock();
try {
ClientResponse response = ldclient.retrieveResource(resource.stringValue());
if(response != null) {
log.info("refreshed resource {}",resource);
CacheEntry newEntry = new CacheEntry();
newEntry.setResource(resource);
newEntry.setExpiryDate(response.getExpires());
newEntry.setLastRetrieved(new Date());
if(entry != null) {
newEntry.setUpdateCount(entry.getUpdateCount()+1);
} else {
newEntry.setUpdateCount(1);
}
newEntry.setTripleCount(response.getData().size());
newEntry.setTriples(response.getData());
backend.putEntry(resource, newEntry);
}