-<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">
+<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.argeo.commons.basic</groupId>
<groupId>org.slf4j</groupId>
<artifactId>com.springsource.slf4j.api</artifactId>
</dependency>
+ <!-- JEE dependencies (for 1.2.16 in SpringSOurce repo)
+ <dependency>
+ <groupId>org.apache.geronimo.specs</groupId>
+ <artifactId>com.springsource.javax.management.j2ee</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>javax.ejb</groupId>
+ <artifactId>com.springsource.javax.ejb</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>javax.transaction</groupId>
+ <artifactId>com.springsource.javax.transaction</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>javax.xml.rpc</groupId>
+ <artifactId>com.springsource.javax.xml.rpc</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>javax.xml.soap</groupId>
+ <artifactId>com.springsource.javax.xml.soap</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>javax.activation</groupId>
+ <artifactId>com.springsource.javax.activation</artifactId>
+ </dependency> -->
</dependencies>
</project>
\ No newline at end of file
-<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">
+<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.argeo.commons.server</groupId>
<artifactId>org.argeo.server.dep.jackrabbit.server</artifactId>
<packaging>pom</packaging>
<name>Dep Jack Rabbit Server</name>
+ <build>
+ <plugins>
+ <plugin>
+ <groupId>org.argeo.maven.plugins</groupId>
+ <artifactId>maven-argeo-osgi-plugin</artifactId>
+ <version>${version.maven-argeo-osgi}</version>
+ <executions>
+ <execution>
+ <id>check-osgi</id>
+ <phase>test</phase>
+ <goals>
+ <goal>equinox</goal>
+ </goals>
+ <configuration>
+ <useDependencies>true</useDependencies>
+ <onlyCheck>true</onlyCheck>
+ <argsToAppend>
+ <arg>-clean</arg>
+ </argsToAppend>
+ <systemProperties>
+ <!-- Make sure that no bundle will be started -->
+ <argeo.osgi.start>XXX</argeo.osgi.start>
+ </systemProperties>
+ </configuration>
+ </execution>
+ </executions>
+ </plugin>
+ </plugins>
+ </build>
<dependencies>
<dependency>
<groupId>org.argeo.dep.osgi</groupId>
<artifactId>com.springsource.org.apache.xalan</artifactId>
</dependency>
- <!-- For webdav -->
+ <!-- Transitive dependencies -->
+ <dependency>
+ <groupId>org.argeo.dep.osgi</groupId>
+ <artifactId>org.argeo.dep.osgi.jcr</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.lucene</groupId>
+ <artifactId>com.springsource.org.apache.lucene</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.argeo.commons.basic</groupId>
+ <artifactId>org.argeo.basic.dep.log4j</artifactId>
+ <version>0.2.2-SNAPSHOT</version>
+ <type>pom</type>
+ </dependency>
+
+ <!-- Commons -->
+ <dependency>
+ <groupId>org.apache.commons</groupId>
+ <artifactId>com.springsource.org.apache.commons.collections</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.commons</groupId>
+ <artifactId>com.springsource.org.apache.commons.io</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.commons</groupId>
+ <artifactId>com.springsource.org.apache.commons.httpclient</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.commons</groupId>
+ <artifactId>com.springsource.org.apache.commons.fileupload</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.commons</groupId>
+ <artifactId>com.springsource.org.apache.commons.compress</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.commons</groupId>
+ <artifactId>com.springsource.org.apache.commons.pool</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.commons</groupId>
+ <artifactId>com.springsource.org.apache.commons.dbcp</artifactId>
+ </dependency>
+
+ <!-- Misc -->
+ <dependency>
+ <groupId>edu.oswego.cs.concurrent</groupId>
+ <artifactId>com.springsource.edu.oswego.cs.dl.util.concurrent</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.derby</groupId>
+ <artifactId>com.springsource.org.apache.derby</artifactId>
+ </dependency>
+
+ <!-- For webdav -->
<dependency>
<groupId>org.springframework</groupId>
<artifactId>org.springframework.web.servlet</artifactId>
<groupId>javax.servlet</groupId>
<artifactId>com.springsource.javax.servlet</artifactId>
</dependency>
+
+ <!-- Tika -->
+ <dependency>
+ <groupId>org.argeo.dep.osgi</groupId>
+ <artifactId>org.argeo.dep.osgi.tika</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.argeo.dep.osgi</groupId>
+ <artifactId>org.argeo.dep.osgi.pdfbox</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.argeo.dep.osgi</groupId>
+ <artifactId>org.argeo.dep.osgi.poi</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.argeo.dep.osgi</groupId>
+ <artifactId>org.argeo.dep.osgi.boilerpipe</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.argeo.dep.osgi</groupId>
+ <artifactId>org.argeo.dep.osgi.bouncycastle.jdk15</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.argeo.dep.osgi</groupId>
+ <artifactId>org.argeo.dep.osgi.drewnoakes.metadata_extractor</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.argeo.dep.osgi</groupId>
+ <artifactId>org.argeo.dep.osgi.netcdf</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.argeo.dep.osgi</groupId>
+ <artifactId>org.argeo.dep.osgi.tagsoup</artifactId>
+ </dependency>
+
+ <!-- Logback <dependency> <groupId>ch.qos.logback</groupId> <artifactId>com.springsource.ch.qos.logback.classic</artifactId>
+ </dependency> <dependency> <groupId>ch.qos.logback</groupId> <artifactId>com.springsource.ch.qos.logback.core</artifactId>
+ </dependency> -->
+
+ <!-- Required for OSGi completion -->
+ <dependency>
+ <groupId>net.sourceforge.nekohtml</groupId>
+ <artifactId>com.springsource.org.cyberneko.html</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>javax.mail</groupId>
+ <artifactId>com.springsource.javax.mail</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.xmlbeans</groupId>
+ <artifactId>com.springsource.org.apache.xmlbeans</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.dom4j</groupId>
+ <artifactId>com.springsource.org.dom4j</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>javax.xml.stream</groupId>
+ <artifactId>com.springsource.javax.xml.stream</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.jdom</groupId>
+ <artifactId>com.springsource.org.jdom</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>com.sun.syndication</groupId>
+ <artifactId>com.springsource.com.sun.syndication</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.objectweb.asm</groupId>
+ <artifactId>com.springsource.org.objectweb.asm</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.jaxen</groupId>
+ <artifactId>com.springsource.org.jaxen</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.xmlpull</groupId>
+ <artifactId>com.springsource.org.xmlpull</artifactId>
+ </dependency>
+
+ <dependency>
+ <groupId>org.argeo.commons.osgi</groupId>
+ <artifactId>org.argeo.osgi.boot</artifactId>
+ <version>0.2.2-SNAPSHOT</version>
+ <scope>test</scope>
+ </dependency>
</dependencies>
</project>
\ No newline at end of file
<!-- Jack Rabbit -->
<dependency>
- <groupId>org.argeo.dep.osgi</groupId>
- <artifactId>org.argeo.dep.osgi.jackrabbit</artifactId>
+ <groupId>org.argeo.commons.server</groupId>
+ <artifactId>org.argeo.server.dep.jackrabbit.server</artifactId>
+ <version>${project.version}</version>
+ <type>pom</type>
</dependency>
<dependency>
<groupId>javax.servlet</groupId>
import javax.jcr.Repository;
import javax.jcr.RepositoryException;
import javax.jcr.Session;
+import javax.jcr.Value;
import org.apache.commons.io.FileUtils;
import org.apache.commons.io.IOUtils;
return repository.login(workspaceName);
}
+ public boolean isStandardDescriptor(String key) {
+ // TODO Auto-generated method stub
+ return false;
+ }
+
+ public boolean isSingleValueDescriptor(String key) {
+ // TODO Auto-generated method stub
+ return false;
+ }
+
+ public Value getDescriptorValue(String key) {
+ // TODO Auto-generated method stub
+ return null;
+ }
+
+ public Value[] getDescriptorValues(String key) {
+ // TODO Auto-generated method stub
+ return null;
+ }
+
// BEANS METHODS
public void setHomeDirectory(File homeDirectory) {
this.homeDirectory = homeDirectory;
import junit.framework.TestCase;
import org.apache.commons.io.FileUtils;
+import org.apache.commons.logging.Log;
+import org.apache.commons.logging.LogFactory;
import org.apache.jackrabbit.core.TransientRepository;
import org.argeo.ArgeoException;
public abstract class AbstractJcrTestCase extends TestCase {
+ private final static Log log = LogFactory.getLog(AbstractJcrTestCase.class);
+
private TransientRepository repository;
private Session session = null;
@Override
protected void tearDown() throws Exception {
- if (session != null)
+ if (session != null) {
session.logout();
+ if (log.isDebugEnabled())
+ log.debug("Logout session");
+ }
}
protected Session session() {
if (session == null) {
try {
+ if (log.isDebugEnabled())
+ log.debug("Login session");
session = getRepository().login(
new SimpleCredentials("demo", "demo".toCharArray()));
} catch (Exception e) {
super.init();
if (resourceConfiguration != null) {
- ResourceConfig resourceConfig = new ResourceConfig();
+ ResourceConfig resourceConfig = new ResourceConfig(null);
try {
resourceConfig.parse(resourceConfiguration.getURL());
} catch (IOException e) {
<?xml version="1.0" encoding="UTF-8"?>
<classpath>
- <classpathentry kind="src" path="src/main/java"/>
- <classpathentry kind="src" path="src/test/java"/>
- <classpathentry kind="src" path="src/test/resources"/>
+ <classpathentry kind="src" output="target/classes" path="src/main/java"/>
+ <classpathentry kind="src" output="target/test-classes" path="src/test/java"/>
+ <classpathentry kind="src" output="target/test-classes" path="src/test/resources"/>
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/J2SE-1.5"/>
<classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
<classpathentry kind="output" path="target/classes"/>
com.springsource.edu.oswego.cs.dl.util.concurrent,\
com.springsource.org.apache.derby,\
com.springsource.org.apache.lucene,\
- com.springsource.junit
+ com.springsource.junit,\
+ com.springsource.org.apache.xml.serializer,\
+ com.springsource.org.apache.commons.dbcp,\
+ com.springsource.org.apache.commons.pool,\
-<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">
+<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.argeo.commons.server</groupId>
</instructions>
</configuration>
</plugin>
+ <plugin>
+ <groupId>org.argeo.maven.plugins</groupId>
+ <artifactId>maven-argeo-osgi-plugin</artifactId>
+ <version>${version.maven-argeo-osgi}</version>
+ <configuration>
+ <useDependencies>true</useDependencies>
+ <onlyCheck>true</onlyCheck>
+ <argsToAppend>
+ <arg>-clean</arg>
+ </argsToAppend>
+ <systemProperties>
+ <!-- Make sure that no bundle will be started -->
+ <argeo.osgi.start>XXX</argeo.osgi.start>
+ </systemProperties>
+ </configuration>
+ </plugin>
</plugins>
</build>
<dependencies>
<!-- JCR -->
<dependency>
- <groupId>javax.jcr</groupId>
- <artifactId>com.springsource.javax.jcr</artifactId>
+ <groupId>org.argeo.dep.osgi</groupId>
+ <artifactId>org.argeo.dep.osgi.jcr</artifactId>
</dependency>
<!-- Spring -->
<type>pom</type>
<scope>test</scope>
</dependency>
+ <dependency>
+ <groupId>org.argeo.commons.osgi</groupId>
+ <artifactId>org.argeo.osgi.boot</artifactId>
+ <version>0.2.2-SNAPSHOT</version>
+ <scope>test</scope>
+ </dependency>
</dependencies>
</project>
@Override
protected void setUp() throws Exception {
+ log.debug("SET UP");
super.setUp();
jra = new JcrResourceAdapter();
jra.setSession(session());
}
+ @Override
+ protected void tearDown() throws Exception {
+ log.debug("TEAR DOWN");
+ super.tearDown();
+ }
+
protected File getRepositoryFile() throws Exception {
Resource res = new ClassPathResource(
"org/argeo/server/jcr/repository.xml");