You are viewing a plain text version of this content. The canonical link for it is here.
Posted to oak-issues@jackrabbit.apache.org by "Ioan-Cristian Linte (JIRA)" <ji...@apache.org> on 2017/06/29 16:00:02 UTC

[jira] [Created] (OAK-6410) NPE when removing inexistent property from checked in node

Ioan-Cristian Linte created OAK-6410:
----------------------------------------

             Summary: NPE when removing inexistent property from checked in node
                 Key: OAK-6410
                 URL: https://issues.apache.org/jira/browse/OAK-6410
             Project: Jackrabbit Oak
          Issue Type: Bug
          Components: jcr
    Affects Versions: 1.6.1
            Reporter: Ioan-Cristian Linte
            Priority: Minor


While running AEM 6.3 which uses oak 1.6.1 the following exception was seen in the logs:
Stacktrace:
java.lang.NullPointerException: null
at org.apache.jackrabbit.oak.jcr.session.NodeImpl$37.checkPreconditions(NodeImpl.java:1449)
at org.apache.jackrabbit.oak.jcr.delegate.SessionDelegate.prePerform(SessionDelegate.java:615)
at org.apache.jackrabbit.oak.jcr.delegate.SessionDelegate.perform(SessionDelegate.java:205)
at org.apache.jackrabbit.oak.jcr.session.ItemImpl.perform(ItemImpl.java:112)
at org.apache.jackrabbit.oak.jcr.session.NodeImpl.internalRemoveProperty(NodeImpl.java:1444)
at org.apache.jackrabbit.oak.jcr.session.NodeImpl.setProperty(NodeImpl.java:354)
....... AEM Code

I have reproduced the NPE with the following code:
{code:java}
Node parent = session.getRootNode().addNode("parent", "nt:unstructured");
Node child = parent.addNode("child", "nt:unstructured");
child.addMixin("mix:versionable");
session.save();
session.getWorkspace().getVersionManager().checkin(child.getPath());
Node node = (Node) session.getItem("/parent/child");
node.setProperty("inexistent", (Value) null);
{code}




--
This message was sent by Atlassian JIRA
(v6.4.14#64029)