* Matching items are removed from the cache.
*
* @param items items updated
*/
public void itemsUpdated(Collection<InternalVersionItem> items) {
ReadLock lock = acquireReadLock();
try {
synchronized (versionItems) {
for (InternalVersionItem item : items) {
InternalVersionItem cached = versionItems.remove(item.getId());
if (cached != null) {
if (cached instanceof InternalVersionHistoryImpl) {
InternalVersionHistoryImpl vh = (InternalVersionHistoryImpl) cached;
try {
vh.reload();
versionItems.put(vh.getId(), vh);
} catch (RepositoryException e) {
log.warn("Unable to update version history: " + e.toString());
}
}
}
}
}
} finally {
lock.release();
}
}