Hi,

See also http://wiki.apache.org/jackrabbit/RepositoryLock

Regards,
Thomas

On Thu, Dec 10, 2009 at 12:23 PM, Alexander Klimetschek
<[email protected]> wrote:
> On Thu, Dec 10, 2009 at 12:18, anand <[email protected]> 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
> [email protected]
>

Reply via email to