SeamFramework.orgCommunity Documentation
In order to activate ModeShape support within your application, you need to include ModeShape on your classpath. At a minimum, the following maven dependencies must be satisfied.
<dependency>
<groupId>org.modeshape</groupId>
<artifactId>modeshape-jcr</artifactId>
<version>${modeshape.version}</version>
</dependency>
<dependency>
<groupId>org.apache.lucene</groupId>
<artifactId>lucene-core</artifactId>
<version>${lucene.version}</version>
</dependency>
Substitute ${modeshape.version} for the ModeShape version you are running against. Currently, Seam JCR tests against 2.5.0.Final. In addition, Lucene is required to run ModeShape. Please consult the ModeShape getting stated guide for exact versions.
In order to use ModeShape's Repository and Session objects in your application, you must define an injection point using the JcrConfiguration annotation based on ModeShape's required configuration parameters. Please review the ModeShape getting started guide for further details.
@Inject @JcrConfiguration(name="org.modeshape.jcr.URL",value="file:path/to/modeshape.xml?repositoryName=MyRepo") Repository repository; @Inject @JcrConfiguration(name="org.modeshape.jcr.URL",value="file:path/to/modeshape.xml?repositoryName=MyRepo") Session session;