FYI: http://se-jcr.sourceforge.net/index.html
On Tue, 2009-12-29 at 19:06 +0530, Sajith Puravankara wrote: > Hi, > > I am new to jackrabbit. I want to setup a content repository for my > spring web application. > > I am using the tomcat 6.0.13 , spring framework 2.0 and > jackrabbit-standalone-1.5.7.jar and jcr-1.0.jar > > I did the configuration like this. > > web.xml > > <resource-env-ref> > <description>Content Repository</description> > <resource-env-ref-name>jcr/repository</resource-env-ref-name> > > <resource-env-ref-type>javax.jcr.Repository</resource-env-ref-type> > </resource-env-ref> > > applicationContext.xml > > <!-- JNDI Document Repository for J2EE environments --> > <bean id="docRepository" > class="org.springframework.jndi.JndiObjectFactoryBean"> > <property name="jndiName" > value="java:comp/env/jcr/repository" /> > </bean> > > tomcat/conf/context.xml > > <!-- Default set of monitored resources --> > <WatchedResource>WEB-INF/web.xml</WatchedResource> > > > <Resource name="jcr/repository" auth="Container" > type="javax.jcr.Repository" > > factory="org.apache.jackrabbit.core.jndi.BindableRepositoryFactory" > configFilePath="E:\repository.xml" > repHomeDir="E:\testrepository" /> > > tomcat/lib folder > > i put the jackrabbit-standalone-1.5.7.jar and jcr-1.0.jar in this > folder > > > > In the controller( spring) i added the code like this to get the > repository object > > context = new InitialContext(); > Context environment = (Context) > context.lookup("java:comp/env"); > Repository repository = > (Repository)environment.lookup("jcr/repository"); > > Now it is throwing ClassCastException: cannot cast from > BindableRepository to javax.jcr.Repository > > What will be the problem. > > There is any available for the spring jackrabbit implementation. > > I have multiple war files deployed in the server. > So what deployment model will best suited? > > > > >