- boolean result = false;
- if (propMapCurr == null) {
- if (nodeProps.putIfAbsent(node, propMap) == null) {
- result = true;
- }
+
+ boolean propsAdded = false;
+ // Attempt initial add
+ if (nodeProps.putIfAbsent(node, propMap) == null) {
+ propsAdded = true;
+
+ /* Notify listeners only for initial node addition
+ * to avoid expensive tasks triggered by redundant notifications
+ */
+ notifyNode(node, UpdateType.ADDED, propMap);