jackrabbit-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Alexander Klimetschek <aklim...@day.com>
Subject Re: Repository lock
Date Thu, 10 Dec 2009 11:23:09 GMT
On Thu, Dec 10, 2009 at 12:18, anand <simer.anand88@gmail.com> wrote:
> I' m using jackrabbit1.5.6. and tried to start repository from my code.
> Whenever i tried to start it using code then Repository lock comes in
> between.
>
> javax.jcr.RepositoryException: The repository home
> /home/sda_tr1/Desktop/simer/apache-tomcat-6.0.20/bin/jackrabbit appears to
> be already locked by the current process.

This means that there is already a repository running and using the
same repository home. The lock is required, because only one
repository instance can access the same repository home directory at a
time.

> I tired to delete file .lock within jackrabbit then it was fine but from
> last few hours i' m not able run repository even if i delete this .lock
> file.

You should find what already starts the repository. This depends on
what you are using - the standalone or webapp distributions already
provide automatically stared repositories. Deleting the lock file
manually is normally only necessary if the repository crashed and left
the lock file behind.

> Some similar files are created within the versions folder and within
> workspace folder(default, security) of jackrabbit.
>
> Is there any method using which i access the repository using code without
> lock?
> like  isLock(), or something like that.

As this is a vital mechanism, it is completely transparent and not
exposed by the implementation.

Regards,
Alex

-- 
Alexander Klimetschek
alexander.klimetschek@day.com

Mime
View raw message