Index: pom.xml =================================================================== --- pom.xml (revision 972) +++ pom.xml (working copy) @@ -338,6 +338,10 @@ java.io.tmpdir ${basedir}/target + + java.security.debug + configfile + Index: extensions/dna-web-jcr-rest-war/pom.xml =================================================================== --- extensions/dna-web-jcr-rest-war/pom.xml (revision 972) +++ extensions/dna-web-jcr-rest-war/pom.xml (working copy) @@ -1,5 +1,7 @@ - + 4.0.0 dna @@ -10,7 +12,8 @@ dna-web-jcr-rest-war war JBoss DNA JCR REST Servlet - JBoss DNA servlet that provides RESTful access to JCR items + JBoss DNA servlet that provides RESTful access to +JCR items http://labs.jboss.org/dna @@ -42,70 +45,81 @@ resources - - - - - - org.codehaus.cargo - cargo-maven2-plugin + +cargo-maven2-plugin start-container - pre-integration-test + +pre-integration-test - start + +start stop-container - post-integration-test + +post-integration-test - stop + +stop - high + +high - ${project.build.directory}/test-classes/jetty-dna.policy + +configfile + +${project.build.directory}/test-classes +/jetty-dna.policy false - org.apache.maven.plugins - maven-surefire-plugin + +org.apache.maven.plugins + +maven-surefire-plugin true surefire-it - integration-test + +integration-test - test + +test - false + +false + - + \ No newline at end of file Index: dna-jcr/src/main/java/org/jboss/dna/jcr/RepositoryNodeTypeManager.java =================================================================== --- dna-jcr/src/main/java/org/jboss/dna/jcr/RepositoryNodeTypeManager.java (revision 972) +++ dna-jcr/src/main/java/org/jboss/dna/jcr/RepositoryNodeTypeManager.java (working copy) @@ -1413,10 +1413,21 @@ List nodeDefs = new ArrayList( nodeType.getDeclaredChildNodeDefinitions().length); + for (JcrNodeDefinition nodeDef : nodeType.getDeclaredChildNodeDefinitions()) { + nodeDefs.add(nodeDef.with(this.context).with(this)); + } + // Create a new node type that also has the correct property and child node definitions associated + JcrNodeType newNodeType = new JcrNodeType(this.context, this, nodeType.getInternalName(), supertypes, + nodeType.getInternalPrimaryItemName(), nodeDefs, propertyDefs, + nodeType.isMixin(), nodeType.hasOrderableChildNodes()); + typesPendingRegistration.add(newNodeType); + } + + // Make sure the nodes have primary types that are either already registered, or pending registration ... + for (JcrNodeType nodeType : typesPendingRegistration) { for (JcrNodeDefinition nodeDef : nodeType.getDeclaredChildNodeDefinitions()) { JcrNodeType[] requiredPrimaryTypes = new JcrNodeType[nodeDef.requiredPrimaryTypeNames().length]; - int i = 0; for (Name primaryTypeName : nodeDef.requiredPrimaryTypeNames()) { requiredPrimaryTypes[i] = findTypeInMapOrList(primaryTypeName, typesPendingRegistration); @@ -1427,15 +1438,7 @@ } i++; } - - nodeDefs.add(nodeDef.with(this.context).with(this)); } - - // Create a new node type that also has the correct property and child node definitions associated - JcrNodeType newNodeType = new JcrNodeType(this.context, this, nodeType.getInternalName(), supertypes, - nodeType.getInternalPrimaryItemName(), nodeDefs, propertyDefs, - nodeType.isMixin(), nodeType.hasOrderableChildNodes()); - typesPendingRegistration.add(newNodeType); } // Graph.Batch batch = graph.batch();