//TODO: fix once range index has been moved to new architecture
final StoredNode valueReindexRoot = broker.getValueIndex().getReindexRoot(this, oldPath);
broker.getValueIndex().reindex(valueReindexRoot);
//Remove the actual node data
broker.removeNode(transaction, oldNode, oldPath, null);
broker.endRemove(transaction);
newNode.nodeId = oldNode.nodeId;
//Reinsert the new node data
broker.insertNodeAfter(transaction, previousNode, newNode);
final NodePath path = newNode.getPath(currentPath);
broker.indexNode(transaction, newNode, path);