Joscorbe commented on code in PR #1317: URL: https://github.com/apache/jackrabbit-oak/pull/1317#discussion_r1506008713
########## oak-store-document/src/main/java/org/apache/jackrabbit/oak/plugins/document/Commit.java: ########## @@ -354,6 +358,39 @@ private void applyToDocumentStore(RevisionVector baseBranchRevision) boolean commitRootHasChanges = operations.containsKey(commitRootPath); for (UpdateOp op : operations.values()) { NodeDocument.setCommitRoot(op, revision, commitRootDepth); + + // special case for :childOrder updates + if (nodeStore.isChildOrderCleanupEnabled()) { + final Branch localBranch = getBranch(); + if (localBranch != null) { + final NavigableSet<Revision> commits = new TreeSet<>(localBranch.getCommits()); + boolean removePreviousSetOperations = false; + for (Map.Entry<Key, Operation> change : op.getChanges().entrySet()) { + if (":childOrder".equals(change.getKey().getName()) && Operation.Type.SET_MAP_ENTRY == change.getValue().type) { Review Comment: Can we make a constant of `:childOrder`? Specially since it is used a few lines below too. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: dev-unsubscr...@jackrabbit.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org