From 61b41e098a591f7a2f9e8c540e34986563219bb1 Mon Sep 17 00:00:00 2001 From: hns Date: Mon, 26 Nov 2007 12:45:38 +0000 Subject: [PATCH] * Always include local subnode version in lastSubnodeChange checksum. Fixes bug 567 --- src/helma/objectmodel/db/Node.java | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/src/helma/objectmodel/db/Node.java b/src/helma/objectmodel/db/Node.java index 18cfccd7..da1f9d16 100644 --- a/src/helma/objectmodel/db/Node.java +++ b/src/helma/objectmodel/db/Node.java @@ -1199,7 +1199,8 @@ public final class Node implements INode, Serializable { retval = nhandle.getNode(nmgr); } - // This would be an alternative way to do it, without loading the subnodes: + // This would be an alternative way to do it, without loading the subnodes, + // but it currently isn't supported by NodeManager. // if (dbmap != null && dbmap.getSubnodeRelation () != null) // retval = nmgr.getNode (this, subid, dbmap.getSubnodeRelation ()); if ((retval != null) && (retval.parentHandle == null) && @@ -1622,9 +1623,9 @@ public final class Node implements INode, Serializable { */ long getLastSubnodeChange(Relation subRel) { // include dbmap.getLastTypeChange to also reload if the type mapping has changed. + long checkSum = lastSubnodeChange + dbmap.getLastTypeChange(); return subRel.aggressiveCaching ? - lastSubnodeChange + dbmap.getLastTypeChange() : - subRel.otherType.getLastDataChange() + dbmap.getLastTypeChange(); + checkSum : checkSum + subRel.otherType.getLastDataChange(); } /**