implement lazy property fetching in NodeManager.updateNode()
to prevent fetching an object property which doesn't need to be updated
This commit is contained in:
parent
80344147dc
commit
11a9c1bd27
1 changed files with 5 additions and 2 deletions
|
@ -408,11 +408,14 @@ public final class NodeManager {
|
|||
|
||||
for (Enumeration e=dbm.prop2db.keys(); e.hasMoreElements(); ) {
|
||||
String propname = (String) e.nextElement ();
|
||||
Property p = node.getProperty (propname, false);
|
||||
Relation rel = dbm.propertyToColumnName (propname);
|
||||
if (rel != null && rel.readonly)
|
||||
|
||||
// skip properties that don't need to be updated before fetching them
|
||||
if (rel != null && (rel.readonly || rel.virtual || rel.direction != Relation.FORWARD))
|
||||
continue;
|
||||
|
||||
Property p = node.getProperty (propname, false);
|
||||
|
||||
if (p != null && rel != null) {
|
||||
|
||||
if (p.dirty) {
|
||||
|
|
Loading…
Add table
Reference in a new issue