You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@rave.apache.org by un...@apache.org on 2012/05/03 14:17:00 UTC

svn commit: r1333419 - in /rave/sandbox/content-services: ./ rave-jcr-config/src/main/java/org/apache/rave/jcr/ rave-jcr-integration/ rave-jcr-integration/module1/ rave-jcr-integration/module1/src/ rave-jcr-integration/module1/src/main/ rave-jcr-integr...

Author: unico
Date: Thu May  3 12:16:58 2012
New Revision: 1333419

URL: http://svn.apache.org/viewvc?rev=1333419&view=rev
Log:
RAVE-603 a rave-jcr-integration module for integration tests

Added:
    rave/sandbox/content-services/rave-jcr-integration/
    rave/sandbox/content-services/rave-jcr-integration/module1/
    rave/sandbox/content-services/rave-jcr-integration/module1/pom.xml
    rave/sandbox/content-services/rave-jcr-integration/module1/src/
    rave/sandbox/content-services/rave-jcr-integration/module1/src/main/
    rave/sandbox/content-services/rave-jcr-integration/module1/src/main/resources/
    rave/sandbox/content-services/rave-jcr-integration/module1/src/main/resources/META-INF/
    rave/sandbox/content-services/rave-jcr-integration/module1/src/main/resources/META-INF/rave/
    rave/sandbox/content-services/rave-jcr-integration/module1/src/main/resources/META-INF/rave/module.json
    rave/sandbox/content-services/rave-jcr-integration/module1/src/main/resources/foo.cnd
    rave/sandbox/content-services/rave-jcr-integration/module1/src/main/resources/foo.json
    rave/sandbox/content-services/rave-jcr-integration/module2/
    rave/sandbox/content-services/rave-jcr-integration/module2/pom.xml
    rave/sandbox/content-services/rave-jcr-integration/module2/src/
    rave/sandbox/content-services/rave-jcr-integration/module2/src/main/
    rave/sandbox/content-services/rave-jcr-integration/module2/src/main/resources/
    rave/sandbox/content-services/rave-jcr-integration/module2/src/main/resources/META-INF/
    rave/sandbox/content-services/rave-jcr-integration/module2/src/main/resources/META-INF/rave/
    rave/sandbox/content-services/rave-jcr-integration/module2/src/main/resources/META-INF/rave/module.json
    rave/sandbox/content-services/rave-jcr-integration/module2/src/main/resources/bar.cnd
    rave/sandbox/content-services/rave-jcr-integration/module2/src/main/resources/bar.json
    rave/sandbox/content-services/rave-jcr-integration/module2/src/main/resources/foo.json
    rave/sandbox/content-services/rave-jcr-integration/module2/src/main/resources/resources/
    rave/sandbox/content-services/rave-jcr-integration/module2/src/main/resources/resources/images/
    rave/sandbox/content-services/rave-jcr-integration/module2/src/main/resources/resources/images/blank.gif   (with props)
    rave/sandbox/content-services/rave-jcr-integration/pom.xml
    rave/sandbox/content-services/rave-jcr-integration/test/
    rave/sandbox/content-services/rave-jcr-integration/test/pom.xml
    rave/sandbox/content-services/rave-jcr-integration/test/src/
    rave/sandbox/content-services/rave-jcr-integration/test/src/test/
    rave/sandbox/content-services/rave-jcr-integration/test/src/test/java/
    rave/sandbox/content-services/rave-jcr-integration/test/src/test/java/org/
    rave/sandbox/content-services/rave-jcr-integration/test/src/test/java/org/apache/
    rave/sandbox/content-services/rave-jcr-integration/test/src/test/java/org/apache/rave/
    rave/sandbox/content-services/rave-jcr-integration/test/src/test/java/org/apache/rave/jcr/
    rave/sandbox/content-services/rave-jcr-integration/test/src/test/java/org/apache/rave/jcr/RaveSystemTest.java
    rave/sandbox/content-services/rave-jcr-integration/test/src/test/repository/
    rave/sandbox/content-services/rave-jcr-integration/test/src/test/repository/repository.xml
    rave/sandbox/content-services/rave-jcr-integration/test/src/test/repository/workspaces/
    rave/sandbox/content-services/rave-jcr-integration/test/src/test/repository/workspaces/default/
    rave/sandbox/content-services/rave-jcr-integration/test/src/test/repository/workspaces/default/workspace.xml
    rave/sandbox/content-services/rave-jcr-integration/test/src/test/resources/
    rave/sandbox/content-services/rave-jcr-integration/test/src/test/resources/log4j.dtd
    rave/sandbox/content-services/rave-jcr-integration/test/src/test/resources/log4j.xml
    rave/sandbox/content-services/rave-jcr-integration/test/src/test/resources/repositoryHelperPool.properties
    rave/sandbox/content-services/rave-jcr-integration/test/src/test/resources/repositoryStubImpl.properties
Removed:
    rave/sandbox/content-services/rave-jcr-config/src/main/java/org/apache/rave/jcr/ImportExportConstants.java
Modified:
    rave/sandbox/content-services/pom.xml
    rave/sandbox/content-services/rave-jcr-service/pom.xml
    rave/sandbox/content-services/rave-jcr-service/src/main/java/org/apache/rave/jcr/servlet/jackrabbit/JackrabbitRepositoryServlet.java

Modified: rave/sandbox/content-services/pom.xml
URL: http://svn.apache.org/viewvc/rave/sandbox/content-services/pom.xml?rev=1333419&r1=1333418&r2=1333419&view=diff
==============================================================================
--- rave/sandbox/content-services/pom.xml (original)
+++ rave/sandbox/content-services/pom.xml Thu May  3 12:16:58 2012
@@ -168,6 +168,7 @@
     <module>rave-jcr-service</module>
     <module>rave-jcr</module>
     <module>demo-portal</module>
+    <module>rave-jcr-integration</module>
   </modules>
 
   <build>

Added: rave/sandbox/content-services/rave-jcr-integration/module1/pom.xml
URL: http://svn.apache.org/viewvc/rave/sandbox/content-services/rave-jcr-integration/module1/pom.xml?rev=1333419&view=auto
==============================================================================
--- rave/sandbox/content-services/rave-jcr-integration/module1/pom.xml (added)
+++ rave/sandbox/content-services/rave-jcr-integration/module1/pom.xml Thu May  3 12:16:58 2012
@@ -0,0 +1,36 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+  Licensed to the Apache Software Foundation (ASF) under one
+  or more contributor license agreements.  See the NOTICE file
+  distributed with this work for additional information
+  regarding copyright ownership.  The ASF licenses this file
+  to you under the Apache License, Version 2.0 (the
+  "License"); you may not use this file except in compliance
+  with the License.  You may obtain a copy of the License at
+
+      http://www.apache.org/licenses/LICENSE-2.0
+
+  Unless required by applicable law or agreed to in writing,
+  software distributed under the License is distributed on an
+  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+  KIND, either express or implied.  See the License for the
+  specific language governing permissions and limitations
+  under the License.
+-->
+<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+         xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd"
+  >
+  <modelVersion>4.0.0</modelVersion>
+
+  <parent>
+    <groupId>org.apache.rave.sandbox.jcr</groupId>
+    <artifactId>rave-jcr-integration</artifactId>
+    <version>sandbox-SNAPSHOT</version>
+  </parent>
+
+  <artifactId>rave-jcr-integration-module1</artifactId>
+  <name>Apache Rave :: rave-jcr-integration-module1</name>
+  <description>Apache Rave JCR Integration Test Module 1</description>
+  <packaging>jar</packaging>
+
+</project>

Added: rave/sandbox/content-services/rave-jcr-integration/module1/src/main/resources/META-INF/rave/module.json
URL: http://svn.apache.org/viewvc/rave/sandbox/content-services/rave-jcr-integration/module1/src/main/resources/META-INF/rave/module.json?rev=1333419&view=auto
==============================================================================
--- rave/sandbox/content-services/rave-jcr-integration/module1/src/main/resources/META-INF/rave/module.json (added)
+++ rave/sandbox/content-services/rave-jcr-integration/module1/src/main/resources/META-INF/rave/module.json Thu May  3 12:16:58 2012
@@ -0,0 +1,17 @@
+{
+  "name" : "foo",
+  "namespaces" : {
+      "foo" : "http://foo.com/1.0"
+  },
+  "cnds" : {
+    "foo" : {
+      "file" : "foo.cnd"
+    }
+  },
+  "contents" : {
+    "foo" : {
+      "file" : "foo.json",
+      "parent" : "/testroot"
+    }
+  }
+}

Added: rave/sandbox/content-services/rave-jcr-integration/module1/src/main/resources/foo.cnd
URL: http://svn.apache.org/viewvc/rave/sandbox/content-services/rave-jcr-integration/module1/src/main/resources/foo.cnd?rev=1333419&view=auto
==============================================================================
--- rave/sandbox/content-services/rave-jcr-integration/module1/src/main/resources/foo.cnd (added)
+++ rave/sandbox/content-services/rave-jcr-integration/module1/src/main/resources/foo.cnd Thu May  3 12:16:58 2012
@@ -0,0 +1,7 @@
+<'foo'='http://foo.com/1.0'>
+<'nt'='http://www.jcp.org/jcr/nt/1.0'>
+
+[foo:foo] > nt:base
+- qux (long) multiple
++ bar (nt:base)
++ baz (nt:base)
\ No newline at end of file

Added: rave/sandbox/content-services/rave-jcr-integration/module1/src/main/resources/foo.json
URL: http://svn.apache.org/viewvc/rave/sandbox/content-services/rave-jcr-integration/module1/src/main/resources/foo.json?rev=1333419&view=auto
==============================================================================
--- rave/sandbox/content-services/rave-jcr-integration/module1/src/main/resources/foo.json (added)
+++ rave/sandbox/content-services/rave-jcr-integration/module1/src/main/resources/foo.json Thu May  3 12:16:58 2012
@@ -0,0 +1,4 @@
+{
+    "jcr:primaryType" : "foo:foo",
+    "qux" : [ 1 ]
+}
\ No newline at end of file

Added: rave/sandbox/content-services/rave-jcr-integration/module2/pom.xml
URL: http://svn.apache.org/viewvc/rave/sandbox/content-services/rave-jcr-integration/module2/pom.xml?rev=1333419&view=auto
==============================================================================
--- rave/sandbox/content-services/rave-jcr-integration/module2/pom.xml (added)
+++ rave/sandbox/content-services/rave-jcr-integration/module2/pom.xml Thu May  3 12:16:58 2012
@@ -0,0 +1,36 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+  Licensed to the Apache Software Foundation (ASF) under one
+  or more contributor license agreements.  See the NOTICE file
+  distributed with this work for additional information
+  regarding copyright ownership.  The ASF licenses this file
+  to you under the Apache License, Version 2.0 (the
+  "License"); you may not use this file except in compliance
+  with the License.  You may obtain a copy of the License at
+
+      http://www.apache.org/licenses/LICENSE-2.0
+
+  Unless required by applicable law or agreed to in writing,
+  software distributed under the License is distributed on an
+  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+  KIND, either express or implied.  See the License for the
+  specific language governing permissions and limitations
+  under the License.
+-->
+<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+         xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd"
+  >
+  <modelVersion>4.0.0</modelVersion>
+
+  <parent>
+    <groupId>org.apache.rave.sandbox.jcr</groupId>
+    <artifactId>rave-jcr-integration</artifactId>
+    <version>sandbox-SNAPSHOT</version>
+  </parent>
+
+  <artifactId>rave-jcr-integration-module2</artifactId>
+  <name>Apache Rave :: rave-jcr-integration-module2</name>
+  <description>Apache Rave JCR Integration Test Module 2</description>
+  <packaging>jar</packaging>
+
+</project>

Added: rave/sandbox/content-services/rave-jcr-integration/module2/src/main/resources/META-INF/rave/module.json
URL: http://svn.apache.org/viewvc/rave/sandbox/content-services/rave-jcr-integration/module2/src/main/resources/META-INF/rave/module.json?rev=1333419&view=auto
==============================================================================
--- rave/sandbox/content-services/rave-jcr-integration/module2/src/main/resources/META-INF/rave/module.json (added)
+++ rave/sandbox/content-services/rave-jcr-integration/module2/src/main/resources/META-INF/rave/module.json Thu May  3 12:16:58 2012
@@ -0,0 +1,29 @@
+{
+  "name" : "bar",
+  "dependencies" : [ "foo" ],
+  "namespaces" : {
+      "bar" : "http://bar.com/1.0"
+  },
+  "cnds" : {
+    "bar" : {
+      "file" : "bar.cnd"
+    }
+  },
+  "contents" : {
+    "foo" : {
+      "file" : "foo.json",
+      "parent" : "/testroot",
+      "importBehavior" : "merge"
+    },
+    "bar" : {
+      "file" : "bar.json",
+      "parent" : "/testroot/foo"
+    }
+  },
+  "resources" : {
+    "quux" : {
+      "path" : "resources",
+      "parent" : "/testroot"
+    }
+  }
+}

Added: rave/sandbox/content-services/rave-jcr-integration/module2/src/main/resources/bar.cnd
URL: http://svn.apache.org/viewvc/rave/sandbox/content-services/rave-jcr-integration/module2/src/main/resources/bar.cnd?rev=1333419&view=auto
==============================================================================
--- rave/sandbox/content-services/rave-jcr-integration/module2/src/main/resources/bar.cnd (added)
+++ rave/sandbox/content-services/rave-jcr-integration/module2/src/main/resources/bar.cnd Thu May  3 12:16:58 2012
@@ -0,0 +1,4 @@
+<'bar'='http://bar.com/1.0'>
+<'nt'='http://www.jcp.org/jcr/nt/1.0'>
+
+[bar:bar] > nt:base

Added: rave/sandbox/content-services/rave-jcr-integration/module2/src/main/resources/bar.json
URL: http://svn.apache.org/viewvc/rave/sandbox/content-services/rave-jcr-integration/module2/src/main/resources/bar.json?rev=1333419&view=auto
==============================================================================
--- rave/sandbox/content-services/rave-jcr-integration/module2/src/main/resources/bar.json (added)
+++ rave/sandbox/content-services/rave-jcr-integration/module2/src/main/resources/bar.json Thu May  3 12:16:58 2012
@@ -0,0 +1,3 @@
+{
+  "jcr:primaryType" : "bar:bar"
+}
\ No newline at end of file

Added: rave/sandbox/content-services/rave-jcr-integration/module2/src/main/resources/foo.json
URL: http://svn.apache.org/viewvc/rave/sandbox/content-services/rave-jcr-integration/module2/src/main/resources/foo.json?rev=1333419&view=auto
==============================================================================
--- rave/sandbox/content-services/rave-jcr-integration/module2/src/main/resources/foo.json (added)
+++ rave/sandbox/content-services/rave-jcr-integration/module2/src/main/resources/foo.json Thu May  3 12:16:58 2012
@@ -0,0 +1,6 @@
+{
+    "qux" : [ 2 ],
+    "baz" : {
+        "jcr:primaryType" : "bar:bar"
+    }
+}
\ No newline at end of file

Added: rave/sandbox/content-services/rave-jcr-integration/module2/src/main/resources/resources/images/blank.gif
URL: http://svn.apache.org/viewvc/rave/sandbox/content-services/rave-jcr-integration/module2/src/main/resources/resources/images/blank.gif?rev=1333419&view=auto
==============================================================================
Binary file - no diff available.

Propchange: rave/sandbox/content-services/rave-jcr-integration/module2/src/main/resources/resources/images/blank.gif
------------------------------------------------------------------------------
    svn:mime-type = application/octet-stream

Added: rave/sandbox/content-services/rave-jcr-integration/pom.xml
URL: http://svn.apache.org/viewvc/rave/sandbox/content-services/rave-jcr-integration/pom.xml?rev=1333419&view=auto
==============================================================================
--- rave/sandbox/content-services/rave-jcr-integration/pom.xml (added)
+++ rave/sandbox/content-services/rave-jcr-integration/pom.xml Thu May  3 12:16:58 2012
@@ -0,0 +1,53 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+  Licensed to the Apache Software Foundation (ASF) under one
+  or more contributor license agreements.  See the NOTICE file
+  distributed with this work for additional information
+  regarding copyright ownership.  The ASF licenses this file
+  to you under the Apache License, Version 2.0 (the
+  "License"); you may not use this file except in compliance
+  with the License.  You may obtain a copy of the License at
+
+      http://www.apache.org/licenses/LICENSE-2.0
+
+  Unless required by applicable law or agreed to in writing,
+  software distributed under the License is distributed on an
+  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+  KIND, either express or implied.  See the License for the
+  specific language governing permissions and limitations
+  under the License.
+-->
+<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+         xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
+  <modelVersion>4.0.0</modelVersion>
+
+  <parent>
+    <groupId>org.apache.rave.sandbox.jcr</groupId>
+    <artifactId>rave-content-services</artifactId>
+    <version>sandbox-SNAPSHOT</version>
+  </parent>
+
+  <artifactId>rave-jcr-integration</artifactId>
+  <name>Apache Rave :: rave-jcr-integration</name>
+  <description>Apache Rave JCR Integration Test Module</description>
+  <packaging>pom</packaging>
+
+  <build>
+    <plugins>
+      <plugin>
+        <groupId>org.apache.maven.plugins</groupId>
+        <artifactId>maven-deploy-plugin</artifactId>
+        <configuration>
+          <skip>true</skip>
+        </configuration>
+      </plugin>
+    </plugins>
+  </build>
+
+  <modules>
+    <module>module1</module>
+    <module>module2</module>
+    <module>test</module>
+  </modules>
+
+</project>

Added: rave/sandbox/content-services/rave-jcr-integration/test/pom.xml
URL: http://svn.apache.org/viewvc/rave/sandbox/content-services/rave-jcr-integration/test/pom.xml?rev=1333419&view=auto
==============================================================================
--- rave/sandbox/content-services/rave-jcr-integration/test/pom.xml (added)
+++ rave/sandbox/content-services/rave-jcr-integration/test/pom.xml Thu May  3 12:16:58 2012
@@ -0,0 +1,118 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+  Licensed to the Apache Software Foundation (ASF) under one
+  or more contributor license agreements.  See the NOTICE file
+  distributed with this work for additional information
+  regarding copyright ownership.  The ASF licenses this file
+  to you under the Apache License, Version 2.0 (the
+  "License"); you may not use this file except in compliance
+  with the License.  You may obtain a copy of the License at
+
+      http://www.apache.org/licenses/LICENSE-2.0
+
+  Unless required by applicable law or agreed to in writing,
+  software distributed under the License is distributed on an
+  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+  KIND, either express or implied.  See the License for the
+  specific language governing permissions and limitations
+  under the License.
+
+  $Id: pom.xml 1303795 2012-03-22 14:19:45Z ate $
+-->
+<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+         xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd"
+  >
+  <modelVersion>4.0.0</modelVersion>
+
+  <parent>
+    <groupId>org.apache.rave.sandbox.jcr</groupId>
+    <artifactId>rave-jcr-integration</artifactId>
+    <version>sandbox-SNAPSHOT</version>
+  </parent>
+
+  <artifactId>rave-jcr-integration-test</artifactId>
+  <name>Apache Rave :: rave-jcr-integration-test</name>
+  <description>Apache Rave JCR Configuration Integration Test</description>
+  <packaging>jar</packaging>
+
+  <dependencies>
+    <dependency>
+      <groupId>org.apache.jackrabbit</groupId>
+      <artifactId>jackrabbit-jcr-tests</artifactId>
+      <version>${apache.jackrabbit.version}</version>
+      <scope>test</scope>
+    </dependency>
+    <dependency>
+      <groupId>org.apache.jackrabbit</groupId>
+      <artifactId>jackrabbit-core</artifactId>
+      <version>${apache.jackrabbit.version}</version>
+      <scope>test</scope>
+    </dependency>
+    <dependency>
+      <groupId>org.slf4j</groupId>
+      <artifactId>slf4j-log4j12</artifactId>
+    </dependency>
+    <dependency>
+      <groupId>log4j</groupId>
+      <artifactId>log4j</artifactId>
+    </dependency>
+    <dependency>
+      <groupId>org.apache.rave.sandbox.jcr</groupId>
+      <artifactId>rave-jcr-config</artifactId>
+      <version>${project.version}</version>
+    </dependency>
+    <dependency>
+      <groupId>org.apache.rave.sandbox.jcr</groupId>
+      <artifactId>rave-jcr-integration-module1</artifactId>
+      <version>${project.version}</version>
+    </dependency>
+    <dependency>
+      <groupId>org.apache.rave.sandbox.jcr</groupId>
+      <artifactId>rave-jcr-integration-module2</artifactId>
+      <version>${project.version}</version>
+    </dependency>
+  </dependencies>
+
+  <build>
+    <plugins>
+      <plugin>
+        <artifactId>maven-antrun-plugin</artifactId>
+        <executions>
+          <execution>
+            <id>process-test-resources</id>
+            <phase>process-test-resources</phase>
+            <configuration>
+              <target>
+                <copy todir="${project.build.directory}/repository">
+                  <fileset dir="${basedir}/src/test/repository" />
+                </copy>
+              </target>
+            </configuration>
+            <goals>
+              <goal>run</goal>
+            </goals>
+          </execution>
+        </executions>
+        <dependencies>
+          <dependency>
+            <groupId>ant</groupId>
+            <artifactId>ant-optional</artifactId>
+            <version>1.5.3-1</version>
+          </dependency>
+        </dependencies>
+      </plugin>
+      <plugin>
+        <artifactId>maven-surefire-plugin</artifactId>
+        <configuration>
+          <systemProperties>
+            <property>
+              <name>org.apache.jackrabbit.repository.home</name>
+              <value>target/repository</value>
+            </property>
+          </systemProperties>
+        </configuration>
+      </plugin>
+    </plugins>
+  </build>
+
+</project>

Added: rave/sandbox/content-services/rave-jcr-integration/test/src/test/java/org/apache/rave/jcr/RaveSystemTest.java
URL: http://svn.apache.org/viewvc/rave/sandbox/content-services/rave-jcr-integration/test/src/test/java/org/apache/rave/jcr/RaveSystemTest.java?rev=1333419&view=auto
==============================================================================
--- rave/sandbox/content-services/rave-jcr-integration/test/src/test/java/org/apache/rave/jcr/RaveSystemTest.java (added)
+++ rave/sandbox/content-services/rave-jcr-integration/test/src/test/java/org/apache/rave/jcr/RaveSystemTest.java Thu May  3 12:16:58 2012
@@ -0,0 +1,53 @@
+package org.apache.rave.jcr;
+
+import javax.jcr.Node;
+import javax.jcr.Property;
+import javax.jcr.Session;
+
+import org.apache.jackrabbit.test.AbstractJCRTest;
+
+public class RaveSystemTest extends AbstractJCRTest {
+
+    public void testBootstrap() throws Exception {
+        final Session session = getHelper().getSuperuserSession();
+        final System raveSystem = new RaveSystem(session.getRepository(), new TestSystemContext());
+        raveSystem.initialize();
+        raveSystem.update();
+        raveSystem.bootstrap(false);
+
+        assertTrue(session.nodeExists("/testroot/foo"));
+        final Node foo = session.getNode("/testroot/foo");
+        assertTrue(foo.isNodeType("foo:foo"));
+
+        assertTrue(foo.hasProperty("qux"));
+        final Property qux = foo.getProperty("qux");
+        assertTrue(qux.isMultiple());
+        assertEquals(2, qux.getValues().length);
+
+        assertTrue(foo.hasNode("bar"));
+        final Node bar = foo.getNode("bar");
+        assertTrue(bar.isNodeType("bar:bar"));
+
+        assertTrue(session.nodeExists("/testroot/images"));
+        final Node images = session.getNode("/testroot/images");
+        assertTrue(images.isNodeType("nt:folder"));
+
+        assertTrue(session.nodeExists("/testroot/images/blank.gif"));
+        final Node gif = session.getNode("/testroot/images/blank.gif");
+        assertTrue(gif.isNodeType("nt:file"));
+
+    }
+
+    private static class TestSystemContext implements SystemContext {
+
+        @Override
+        public String getMimeType(final String file) {
+            return null;
+        }
+
+        @Override
+        public String getParameter(final String name) {
+            return null;
+        }
+    }
+}

Added: rave/sandbox/content-services/rave-jcr-integration/test/src/test/repository/repository.xml
URL: http://svn.apache.org/viewvc/rave/sandbox/content-services/rave-jcr-integration/test/src/test/repository/repository.xml?rev=1333419&view=auto
==============================================================================
--- rave/sandbox/content-services/rave-jcr-integration/test/src/test/repository/repository.xml (added)
+++ rave/sandbox/content-services/rave-jcr-integration/test/src/test/repository/repository.xml Thu May  3 12:16:58 2012
@@ -0,0 +1,42 @@
+<?xml version="1.0"?>
+<!--
+   Licensed to the Apache Software Foundation (ASF) under one or more
+   contributor license agreements.  See the NOTICE file distributed with
+   this work for additional information regarding copyright ownership.
+   The ASF licenses this file to You under the Apache License, Version 2.0
+   (the "License"); you may not use this file except in compliance with
+   the License.  You may obtain a copy of the License at
+
+       http://www.apache.org/licenses/LICENSE-2.0
+
+   Unless required by applicable law or agreed to in writing, software
+   distributed under the License is distributed on an "AS IS" BASIS,
+   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+   See the License for the specific language governing permissions and
+   limitations under the License.
+  -->
+<!DOCTYPE Repository PUBLIC "-//The Apache Software Foundation//DTD Jackrabbit 1.6//EN" "http://jackrabbit.apache.org/dtd/repository-1.6.dtd">
+<Repository>
+  <FileSystem class="org.apache.jackrabbit.core.fs.mem.MemoryFileSystem"/>
+
+  <DataStore class="org.apache.jackrabbit.core.data.FileDataStore"/>
+
+  <Security appName="Jackrabbit">
+    <SecurityManager class="org.apache.jackrabbit.core.security.simple.SimpleSecurityManager" workspaceName="security"/>
+    <AccessManager class="org.apache.jackrabbit.core.security.simple.SimpleAccessManager"/>
+    <LoginModule class="org.apache.jackrabbit.core.security.simple.SimpleLoginModule"/>
+  </Security>
+
+  <Workspaces rootPath="${rep.home}/workspaces" defaultWorkspace="default" maxIdleTime="2"/>
+
+  <Workspace name="${wsp.name}">
+    <FileSystem class="org.apache.jackrabbit.core.fs.mem.MemoryFileSystem"/>
+    <PersistenceManager class="org.apache.jackrabbit.core.persistence.mem.InMemBundlePersistenceManager"/>
+  </Workspace>
+
+  <Versioning rootPath="${rep.home}/version">
+    <FileSystem class="org.apache.jackrabbit.core.fs.mem.MemoryFileSystem"/>
+    <PersistenceManager class="org.apache.jackrabbit.core.persistence.mem.InMemBundlePersistenceManager"/>
+  </Versioning>
+
+</Repository>

Added: rave/sandbox/content-services/rave-jcr-integration/test/src/test/repository/workspaces/default/workspace.xml
URL: http://svn.apache.org/viewvc/rave/sandbox/content-services/rave-jcr-integration/test/src/test/repository/workspaces/default/workspace.xml?rev=1333419&view=auto
==============================================================================
--- rave/sandbox/content-services/rave-jcr-integration/test/src/test/repository/workspaces/default/workspace.xml (added)
+++ rave/sandbox/content-services/rave-jcr-integration/test/src/test/repository/workspaces/default/workspace.xml Thu May  3 12:16:58 2012
@@ -0,0 +1,21 @@
+<?xml version="1.0"?>
+<!--
+   Licensed to the Apache Software Foundation (ASF) under one or more
+   contributor license agreements.  See the NOTICE file distributed with
+   this work for additional information regarding copyright ownership.
+   The ASF licenses this file to You under the Apache License, Version 2.0
+   (the "License"); you may not use this file except in compliance with
+   the License.  You may obtain a copy of the License at
+
+       http://www.apache.org/licenses/LICENSE-2.0
+
+   Unless required by applicable law or agreed to in writing, software
+   distributed under the License is distributed on an "AS IS" BASIS,
+   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+   See the License for the specific language governing permissions and
+   limitations under the License.
+  -->
+<Workspace name="default">
+  <FileSystem class="org.apache.jackrabbit.core.fs.mem.MemoryFileSystem"/>
+  <PersistenceManager class="org.apache.jackrabbit.core.persistence.mem.InMemBundlePersistenceManager"/>
+</Workspace>
\ No newline at end of file

Added: rave/sandbox/content-services/rave-jcr-integration/test/src/test/resources/log4j.dtd
URL: http://svn.apache.org/viewvc/rave/sandbox/content-services/rave-jcr-integration/test/src/test/resources/log4j.dtd?rev=1333419&view=auto
==============================================================================
--- rave/sandbox/content-services/rave-jcr-integration/test/src/test/resources/log4j.dtd (added)
+++ rave/sandbox/content-services/rave-jcr-integration/test/src/test/resources/log4j.dtd Thu May  3 12:16:58 2012
@@ -0,0 +1,228 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements.  See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License.  You may obtain a copy of the License at
+
+      http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
+
+<!-- Authors: Chris Taylor, Ceki Gulcu. -->
+
+<!-- Version: 1.2 -->
+
+<!-- A configuration element consists of optional renderer
+elements,appender elements, categories and an optional root
+element. -->
+
+<!ELEMENT log4j:configuration (renderer*, appender*,plugin*, (category|logger)*,root?,
+                               (categoryFactory|loggerFactory)?)>
+
+<!-- The "threshold" attribute takes a level value below which -->
+<!-- all logging statements are disabled. -->
+
+<!-- Setting the "debug" enable the printing of internal log4j logging   -->
+<!-- statements.                                                         -->
+
+<!-- By default, debug attribute is "null", meaning that we not do touch -->
+<!-- internal log4j logging settings. The "null" value for the threshold -->
+<!-- attribute can be misleading. The threshold field of a repository	 -->
+<!-- cannot be set to null. The "null" value for the threshold attribute -->
+<!-- simply means don't touch the threshold field, the threshold field   --> 
+<!-- keeps its old value.                                                -->
+     
+<!ATTLIST log4j:configuration
+  xmlns:log4j              CDATA #FIXED "http://jakarta.apache.org/log4j/" 
+  threshold                (all|trace|debug|info|warn|error|fatal|off|null) "null"
+  debug                    (true|false|null)  "null"
+  reset                    (true|false) "false"
+>
+
+<!-- renderer elements allow the user to customize the conversion of  -->
+<!-- message objects to String.                                       -->
+
+<!ELEMENT renderer EMPTY>
+<!ATTLIST renderer
+  renderedClass  CDATA #REQUIRED
+  renderingClass CDATA #REQUIRED
+>
+
+<!-- Appenders must have a name and a class. -->
+<!-- Appenders may contain an error handler, a layout, optional parameters -->
+<!-- and filters. They may also reference (or include) other appenders. -->
+<!ELEMENT appender (errorHandler?, param*,
+      rollingPolicy?, triggeringPolicy?, connectionSource?,
+      layout?, filter*, appender-ref*)>
+<!ATTLIST appender
+  name 		CDATA 	#REQUIRED
+  class 	CDATA	#REQUIRED
+>
+
+<!ELEMENT layout (param*)>
+<!ATTLIST layout
+  class		CDATA	#REQUIRED
+>
+
+<!ELEMENT filter (param*)>
+<!ATTLIST filter
+  class		CDATA	#REQUIRED
+>
+
+<!-- ErrorHandlers can be of any class. They can admit any number of -->
+<!-- parameters. -->
+
+<!ELEMENT errorHandler (param*, root-ref?, logger-ref*,  appender-ref?)> 
+<!ATTLIST errorHandler
+   class        CDATA   #REQUIRED 
+>
+
+<!ELEMENT root-ref EMPTY>
+
+<!ELEMENT logger-ref EMPTY>
+<!ATTLIST logger-ref
+  ref CDATA #REQUIRED
+>
+
+<!ELEMENT param EMPTY>
+<!ATTLIST param
+  name		CDATA   #REQUIRED
+  value		CDATA	#REQUIRED
+>
+
+
+<!-- The priority class is org.apache.log4j.Level by default -->
+<!ELEMENT priority (param*)>
+<!ATTLIST priority
+  class   CDATA	#IMPLIED
+  value	  CDATA #REQUIRED
+>
+
+<!-- The level class is org.apache.log4j.Level by default -->
+<!ELEMENT level (param*)>
+<!ATTLIST level
+  class   CDATA	#IMPLIED
+  value	  CDATA #REQUIRED
+>
+
+
+<!-- If no level element is specified, then the configurator MUST not -->
+<!-- touch the level of the named category. -->
+<!ELEMENT category (param*,(priority|level)?,appender-ref*)>
+<!ATTLIST category
+  class         CDATA   #IMPLIED
+  name		CDATA	#REQUIRED
+  additivity	(true|false) "true"  
+>
+
+<!-- If no level element is specified, then the configurator MUST not -->
+<!-- touch the level of the named logger. -->
+
+<!ELEMENT logger (level?,appender-ref*)>
+<!ATTLIST logger
+  name		CDATA	#REQUIRED
+  additivity	(true|false) "true"  
+>
+
+
+<!ELEMENT categoryFactory (param*)>
+<!ATTLIST categoryFactory 
+   class        CDATA #REQUIRED>
+
+<!ELEMENT loggerFactory (param*)>
+<!ATTLIST loggerFactory
+   class        CDATA #REQUIRED>
+
+<!ELEMENT appender-ref EMPTY>
+<!ATTLIST appender-ref
+  ref CDATA #REQUIRED
+>
+
+<!-- plugins must have a name and class and can have optional parameters -->
+<!ELEMENT plugin (param*, connectionSource?)>
+<!ATTLIST plugin
+  name 		CDATA 	   #REQUIRED
+  class 	CDATA  #REQUIRED
+>
+
+<!ELEMENT connectionSource (dataSource?, param*)>
+<!ATTLIST connectionSource
+  class        CDATA  #REQUIRED
+>
+
+<!ELEMENT dataSource (param*)>
+<!ATTLIST dataSource
+  class        CDATA  #REQUIRED
+>
+
+<!ELEMENT triggeringPolicy ((param|filter)*)>
+<!ATTLIST triggeringPolicy
+  name 		CDATA  #IMPLIED
+  class 	CDATA  #REQUIRED
+>
+
+<!ELEMENT rollingPolicy (param*)>
+<!ATTLIST rollingPolicy
+  name 		CDATA  #IMPLIED
+  class 	CDATA  #REQUIRED
+>
+
+
+<!-- If no priority element is specified, then the configurator MUST not -->
+<!-- touch the priority of root. -->
+<!-- The root category always exists and cannot be subclassed. -->
+<!ELEMENT root (param*, (priority|level)?, appender-ref*)>
+
+
+<!-- ==================================================================== -->
+<!--                       A logging event                                -->
+<!-- ==================================================================== -->
+<!ELEMENT log4j:eventSet (log4j:event*)>
+<!ATTLIST log4j:eventSet
+  xmlns:log4j             CDATA #FIXED "http://jakarta.apache.org/log4j/" 
+  version                (1.1|1.2) "1.2" 
+  includesLocationInfo   (true|false) "true"
+>
+
+
+
+<!ELEMENT log4j:event (log4j:message, log4j:NDC?, log4j:throwable?, 
+                       log4j:locationInfo?, log4j:properties?) >
+
+<!-- The timestamp format is application dependent. -->
+<!ATTLIST log4j:event
+    logger     CDATA #REQUIRED
+    level      CDATA #REQUIRED
+    thread     CDATA #REQUIRED
+    timestamp  CDATA #REQUIRED
+    time       CDATA #IMPLIED
+>
+
+<!ELEMENT log4j:message (#PCDATA)>
+<!ELEMENT log4j:NDC (#PCDATA)>
+
+<!ELEMENT log4j:throwable (#PCDATA)>
+
+<!ELEMENT log4j:locationInfo EMPTY>
+<!ATTLIST log4j:locationInfo
+  class  CDATA	#REQUIRED
+  method CDATA	#REQUIRED
+  file   CDATA	#REQUIRED
+  line   CDATA	#REQUIRED
+>
+
+<!ELEMENT log4j:properties (log4j:data*)>
+
+<!ELEMENT log4j:data EMPTY>
+<!ATTLIST log4j:data
+  name   CDATA	#REQUIRED
+  value  CDATA	#REQUIRED
+>

Added: rave/sandbox/content-services/rave-jcr-integration/test/src/test/resources/log4j.xml
URL: http://svn.apache.org/viewvc/rave/sandbox/content-services/rave-jcr-integration/test/src/test/resources/log4j.xml?rev=1333419&view=auto
==============================================================================
--- rave/sandbox/content-services/rave-jcr-integration/test/src/test/resources/log4j.xml (added)
+++ rave/sandbox/content-services/rave-jcr-integration/test/src/test/resources/log4j.xml Thu May  3 12:16:58 2012
@@ -0,0 +1,51 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!--
+  Licensed to the Apache Software Foundation (ASF) under one
+  or more contributor license agreements.  See the NOTICE file
+  distributed with this work for additional information
+  regarding copyright ownership.  The ASF licenses this file
+  to you under the Apache License, Version 2.0 (the
+  "License"); you may not use this file except in compliance
+  with the License.  You may obtain a copy of the License at
+
+      http://www.apache.org/licenses/LICENSE-2.0
+
+  Unless required by applicable law or agreed to in writing,
+  software distributed under the License is distributed on an
+  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+  KIND, either express or implied.  See the License for the
+  specific language governing permissions and limitations
+  under the License.
+-->
+<!DOCTYPE log4j:configuration SYSTEM "log4j.dtd">
+<log4j:configuration xmlns:log4j="http://jakarta.apache.org/log4j/">
+
+  <!-- ====================================================================== -->
+  <!-- A P P E N D E R S                                                      -->
+  <!-- ====================================================================== -->
+
+  <!-- console -->
+  <appender name="console" class="org.apache.log4j.ConsoleAppender">
+    <layout class="org.apache.log4j.PatternLayout">
+      <param name="ConversionPattern" value="%d{dd.MM.yyyy HH:mm:ss} %-5p [%C.%M():%L] %m%n"/>
+    </layout>
+  </appender>
+
+  <!-- ====================================================================== -->
+  <!-- L O G G E R S                                                          -->
+  <!-- ====================================================================== -->
+  <category additivity="false" name="org.apache.jackrabbit.core">
+    <level value="warn"/>
+    <appender-ref ref="console"/>
+  </category>
+  <category additivity="false" name="org.apache.rave.jcr">
+    <level value="info"/>
+    <appender-ref ref="console"/>
+  </category>
+
+  <root>
+    <level value="warn"/>
+    <appender-ref ref="console"/>
+  </root>
+
+</log4j:configuration>

Added: rave/sandbox/content-services/rave-jcr-integration/test/src/test/resources/repositoryHelperPool.properties
URL: http://svn.apache.org/viewvc/rave/sandbox/content-services/rave-jcr-integration/test/src/test/resources/repositoryHelperPool.properties?rev=1333419&view=auto
==============================================================================
--- rave/sandbox/content-services/rave-jcr-integration/test/src/test/resources/repositoryHelperPool.properties (added)
+++ rave/sandbox/content-services/rave-jcr-integration/test/src/test/resources/repositoryHelperPool.properties Thu May  3 12:16:58 2012
@@ -0,0 +1,17 @@
+#  Licensed to the Apache Software Foundation (ASF) under one or more
+#  contributor license agreements.  See the NOTICE file distributed with
+#  this work for additional information regarding copyright ownership.
+#  The ASF licenses this file to You under the Apache License, Version 2.0
+#  (the "License"); you may not use this file except in compliance with
+#  the License.  You may obtain a copy of the License at
+#
+#      http://www.apache.org/licenses/LICENSE-2.0
+#
+#  Unless required by applicable law or agreed to in writing, software
+#  distributed under the License is distributed on an "AS IS" BASIS,
+#  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+#  See the License for the specific language governing permissions and
+#  limitations under the License.
+
+# first helper uses default values
+helper.0.=

Added: rave/sandbox/content-services/rave-jcr-integration/test/src/test/resources/repositoryStubImpl.properties
URL: http://svn.apache.org/viewvc/rave/sandbox/content-services/rave-jcr-integration/test/src/test/resources/repositoryStubImpl.properties?rev=1333419&view=auto
==============================================================================
--- rave/sandbox/content-services/rave-jcr-integration/test/src/test/resources/repositoryStubImpl.properties (added)
+++ rave/sandbox/content-services/rave-jcr-integration/test/src/test/resources/repositoryStubImpl.properties Thu May  3 12:16:58 2012
@@ -0,0 +1,17 @@
+#  Licensed to the Apache Software Foundation (ASF) under one or more
+#  contributor license agreements.  See the NOTICE file distributed with
+#  this work for additional information regarding copyright ownership.
+#  The ASF licenses this file to You under the Apache License, Version 2.0
+#  (the "License"); you may not use this file except in compliance with
+#  the License.  You may obtain a copy of the License at
+#
+#      http://www.apache.org/licenses/LICENSE-2.0
+#
+#  Unless required by applicable law or agreed to in writing, software
+#  distributed under the License is distributed on an "AS IS" BASIS,
+#  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+#  See the License for the specific language governing permissions and
+#  limitations under the License.
+
+# Stub implementation class
+javax.jcr.tck.repository_stub_impl=org.apache.jackrabbit.core.JackrabbitRepositoryStub

Modified: rave/sandbox/content-services/rave-jcr-service/pom.xml
URL: http://svn.apache.org/viewvc/rave/sandbox/content-services/rave-jcr-service/pom.xml?rev=1333419&r1=1333418&r2=1333419&view=diff
==============================================================================
--- rave/sandbox/content-services/rave-jcr-service/pom.xml (original)
+++ rave/sandbox/content-services/rave-jcr-service/pom.xml Thu May  3 12:16:58 2012
@@ -42,7 +42,11 @@
       <artifactId>jackrabbit-jcr-servlet</artifactId>
       <version>${apache.jackrabbit.version}</version>
     </dependency>
-
+    <dependency>
+      <groupId>org.apache.rave.sandbox.jcr</groupId>
+      <artifactId>rave-jcr-config</artifactId>
+      <version>${project.version}</version>
+    </dependency>
   </dependencies>
 
 </project>

Modified: rave/sandbox/content-services/rave-jcr-service/src/main/java/org/apache/rave/jcr/servlet/jackrabbit/JackrabbitRepositoryServlet.java
URL: http://svn.apache.org/viewvc/rave/sandbox/content-services/rave-jcr-service/src/main/java/org/apache/rave/jcr/servlet/jackrabbit/JackrabbitRepositoryServlet.java?rev=1333419&r1=1333418&r2=1333419&view=diff
==============================================================================
--- rave/sandbox/content-services/rave-jcr-service/src/main/java/org/apache/rave/jcr/servlet/jackrabbit/JackrabbitRepositoryServlet.java (original)
+++ rave/sandbox/content-services/rave-jcr-service/src/main/java/org/apache/rave/jcr/servlet/jackrabbit/JackrabbitRepositoryServlet.java Thu May  3 12:16:58 2012
@@ -18,12 +18,18 @@
  */
 package org.apache.rave.jcr.servlet.jackrabbit;
 
+import java.io.File;
 import java.net.MalformedURLException;
 import java.net.URL;
 
+import javax.jcr.RepositoryException;
 import javax.servlet.ServletConfig;
 import javax.servlet.ServletException;
 
+import org.apache.rave.jcr.RaveSystem;
+import org.apache.rave.jcr.bootstrapping.BootstrapException;
+import org.apache.rave.jcr.servlet.ServletSystemContext;
+
 /**
  * Extended version of the JackrabbitRepositoryServlet to allow overriding of the
  * <code>repository.home</code> and <code>repository.config</code> location init parameters through system properties.
@@ -138,4 +144,21 @@ public class JackrabbitRepositoryServlet
         repositoryConfig = getLocationParam(config, REPOSITORY_CONFIG_PARAM, null);
         super.init(config);
     }
+
+    @Override
+    public void init() throws ServletException {
+        super.init();
+        try {
+            // FIXME: when super.init finishes the repository is already available for clients, but then the system
+            // is not yet initialized and bootstrapped
+            final RaveSystem raveSystem = new RaveSystem(getRepository(), new ServletSystemContext(getServletConfig()));
+            raveSystem.initialize();
+            raveSystem.update();
+            raveSystem.bootstrap(true);
+        } catch (BootstrapException e) {
+            throw new ServletException(e.getMessage(), e);
+        } catch (RepositoryException e) {
+            throw new ServletException(e.getMessage(), e);
+        }
+    }
 }