1 Reply Latest reply on Apr 22, 2014 4:06 AM by Horia Chiorean

    Check in of imported node fails

    Alexey Shashov Newbie

      Hello.

       

      I'm using modeshape 3.7.2.Final. I'm made an application, that imports a node from XML. Then I try to check in a versionable child of that node (sv:name="demoPDT"), using versionManager.checkin method, and get the following error:

       

      java.lang.NullPointerException

          at org.modeshape.jcr.SystemContent.nextNameForVersionNode(SystemContent.java:1193)

          at org.modeshape.jcr.SystemContent.recordNewVersion(SystemContent.java:1087)

          at org.modeshape.jcr.JcrVersionManager.checkin(JcrVersionManager.java:356)

          at org.modeshape.jcr.JcrVersionManager.checkin(JcrVersionManager.java:304)

          at org.modeshape.example.jdbcstore.ModeShapeExample.main(ModeShapeExample.java:125)

       

      My xml is attached below, I got that xml by using session.exportSystemView method in modeshape 2.8.3.Final. The import itself worked fine, I can see all the imported nodes and read their properties.

      I thought, that this error might be related to the fact, that version history is not imported. I tried removing jcr:baseVersion and jcr:predecessors from xml (the attached version has them already removed), since they hold a reference, that is no longer valid in modeshape 3.7.2. It didn't change the error.

      I don't think that this error is related to my modeshape or infinispan configurations, since everything else is working fine, but I attached it below anyway.

      Do you think there is a way to change an xml to make it possible to check in without error? Could there be some other solution?

       

      Thanks

      Alexey