You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@jackrabbit.apache.org by Fabrizio Giustina <fg...@gmail.com> on 2005/10/02 16:05:38 UTC

Re: shutting down repository obtained from jndi via spring

Hi Hedgar

On 9/29/05, Edgar Poce <ed...@gmail.com> wrote:
> On 9/28/05, Brian Moseley <bc...@osafoundation.org> wrote:
> > since updating to the latest jackrabbit source, i'm finding that a
> > normal server shutdown does not cause the repository to be shutdown. the
> > repository lock file is not removed, and i can not successfully reopen
> > the repository when restarting tomcat.
>
> I think it shouldn't happen, could you please post a jira issue and
> provide the configuration details?. I added the repository lock
> recently but it shouldn't have broken anything.

I don't think the lock can have broken anything: at least for me the
shutdown didn't work properly also before (the repository was not
locked at restart, but anyway was not closed cleanly).

The reason for me appears to be http://issues.apache.org/jira/browse/JCR-120:
it was fixed some time ago, but after changes to jackrabbit now it
continues to break on different classes (also non-jackrabbit ones,
like commons-collection). A ServletContextListener do the job, as it
appers to be executed before tomcat stop loading new classes.

Other options are moving the jackrabbit jars and dependencies to
tomcat shared libs (but that's pretty bad), or continue fixing JCR-120
preloading a bunch of other classes. None of them are satisfying, so
unless we can find how to make tomcat allow jackrabbit load classes
during shutdown I can't come up with a better solution than a context
listener...

fabrizio

Re: shutting down repository obtained from jndi via spring

Posted by Jukka Zitting <ju...@zitting.name>.
Hi,

Fabrizio Giustina wrote:
> The reason for me appears to be http://issues.apache.org/jira/browse/JCR-120:
> it was fixed some time ago, but after changes to jackrabbit now it
> continues to break on different classes (also non-jackrabbit ones,
> like commons-collection). A ServletContextListener do the job, as it
> appers to be executed before tomcat stop loading new classes.

Ah, just as I expected, the JCR-120 fix did eventually get broken. :-(

I reopened the JCR-120 bug with an idea of how this issue should be 
handled. I'd
like to remove the shutdown hook from RepositoryImpl and require all 
client code
to explicitly shut down the repository they've instantiated. Otherwise I don't
think we'll ever find a proper solution to this class loading issue.

BR,

Jukka Zitting