diff --git a/src/helma/objectmodel/db/Node.java b/src/helma/objectmodel/db/Node.java index 3cd71f49..04aa2133 100644 --- a/src/helma/objectmodel/db/Node.java +++ b/src/helma/objectmodel/db/Node.java @@ -168,6 +168,9 @@ public final class Node implements INode, Serializable { public void invokeOnInit() { // Invoke onInit() if it is defined by this Node's prototype if (dbmap != null) { + // register node with local thread, or else we risk infinite recursion in onInit() + if (Thread.currentThread() instanceof Transactor) + ((Transactor) Thread.currentThread()).visitCleanNode(this); try { // We need to reach deap into helma.framework.core to invoke onInit(), // but the functionality is neat so we got to be strong here.