I'm trying to bind a Jackrabbit repository in JNDI under JBoss (4.0.3SP1). In
the Jackrabbit documentation, they describe how to do this under tomcat using
the GlobalNamingResources/Resource tags in server.xml and ResourceLink tag in
context.xml. This all works fine.
Now I want to do the same thing under JBoss. I've tried modifying server.xml
and context.xml in jbossweb-tomcat55.sar, but this doesn't appear to work.
I've looked at using JNDIBindingServiceMgr, but I can't figure out how to use
it for this type of binding.
Anyway, here's the Resource entry from tomcat:
<Resource name="jcr/globalRepository"
| auth="Container"
| type="javax.jcr.Repository"
| factory="org.apache.jackrabbit.core.jndi.BindableRepositoryFactory"
| configFilePath="/path/to/repository.xml"
| repHomeDir="/path/to/repository"/>
Here's the ResourceLink from tomcat:
<ResourceLink name="jcr/globalRepository"
| global="jcr/globalRepository"
| type="javax.jcr.Repository"/>
In my servlet on tomcat, I can then simply do the following to locate the
repository:
InitialContext nameCtx = new InitialContext();
| Context environment = (Context) nameCtx.lookup("java:comp/env");
| Repository repository =
| (Repository) environment.lookup("jcr/globalRepository");
Can anyone shed some light on how to do this in JBoss?
Thanks!
Mark
View the original post :
http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3938680#3938680
Reply to the post :
http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3938680
-------------------------------------------------------
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
_______________________________________________
JBoss-user mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/jboss-user