jackrabbit-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Edgar Poce <edgarp...@gmail.com>
Subject Re: Deployment Model 2 questions
Date Sun, 04 Dec 2005 14:45:44 GMT
Hi alexandru,

Alexandru Popescu wrote:
> [quote]
>  Place the Jackrabbit jar file and all the dependencies (including the 
> JCR API jar file) under [Tomcat folder]/common/lib.
> [/quote]
> Now my question is: is this really necessary? I am thinking that the 
> only jar file needed in the common/lib is the jcr jar.

AFAIK, in order to run a shared jackrabbit instance all the classes must 
be loaded by the same classloader. In Tomcat in can be achieved by 
placing all the needed jars at the server level.

> Considering 2 applications accessing the shared JCR, only the first one 
> requesting from JNDI the repository will really need to provide the 
> jackrabbit classes. 
I'm not sure, I haven't tested it but I guess you would get a 
ClassNotFoundException if you try this configuration. AFAIK if you 
define a shared resource the shared jars must be placed under 
${TOMCAT_HOME}/common/lib or any common path, see 
${TOMCAT_HOME}/conf/catalina.properties#common.loader. The idea behind a 
shared resource is that no webapp need to know anything about the 
concrete implementation. Moreover in the scenario you are describing the 
correct behavior of your webapps would depend in the order in which the 
web applications are accessed, which doesn't seem to be a good option.


ps, it's pretty much the same with other embedded resources.
  (The enterprise scenario)

> thanks a lot in advance,
> ./alex
> -- 
> .w( the_mindstorm )p.
> [1] 
> http://incubator.apache.org/jackrabbit/doc/arch/deploy/howto-model2.html

View raw message