rishabhdaim commented on code in PR #560:
URL: https://github.com/apache/jackrabbit-oak/pull/560#discussion_r873931040


##########
oak-store-document/src/main/java/org/apache/jackrabbit/oak/plugins/document/DocumentNodeState.java:
##########
@@ -414,6 +414,11 @@ public String toString() {
      * @param revision the revision this node is created.
      */
     UpdateOp asOperation(@NotNull Revision revision) {
+
+        if (Utils.isNodeNameLong(path, 
store.getDocumentStore().getNodeNameLimit())) {
+            throw new DocumentStoreException("Node name is too long: " + path);
+        }
+

Review Comment:
   For a Node Name to be long, there must be parent path which is long as well. 
   
   Since `UpdateOp` doesn't have path (parent for newly added node), so I don't 
we can move this check to `UpdateOp`.



-- 
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: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to