OPENJPA-1151 committing patch from Jody Grassel.

modified:   openjpa-kernel/src/main/java/org/apache/openjpa/datacache/AbstractQueryCache.java

git-svn-id: https://svn.apache.org/repos/asf/openjpa/trunk@790003 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Michael Dick 2009-06-30 23:53:31 +00:00
parent db2082dea4
commit 80dbd79952
1 changed files with 5 additions and 4 deletions

View File

@ -120,12 +120,13 @@ public abstract class AbstractQueryCache
} else {
Collection changedTypes = ev.getTypes();
HashMap<String,Long> changedClasses =
new HashMap<String,Long>();
new HashMap<String,Long>();
Long tstamp = new Long(System.currentTimeMillis());
for (Object o: changedTypes) {
String name = ((Class) o).getName();
if(!changedClasses.containsKey(name))
changedClasses.put(name,
new Long(System.currentTimeMillis()));
if(!changedClasses.containsKey(name)) {
changedClasses.put(name, tstamp );
}
}
// Now update entity timestamp map
updateEntityTimestamp(changedClasses);