jackrabbit-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Samuel Cox <crankydi...@gmail.com>
Subject Re: RepositoryCopier requires shutdown of source repositoy?
Date Tue, 15 Dec 2009 18:01:38 GMT
Jukka Zitting wrote:
> Hi,
> 
> On Thu, Dec 10, 2009 at 1:34 PM, Samuel Cox <crankydillo@gmail.com> wrote:
>> I need to backup our repository periodically and anticipate using the
>> RepositoryCopier class.  I was curious that 2 of the methods in the Javadoc
>> mention that the source repo must not be modified during the call; however,
>> the others do not.  Is it possible for me to perform a backup while still
>> allowing JCR API calls that modify the repo?  In other words, will
>> RepositoryCopier somehow lock/cache/unlock/flush/etc for me?
>>  I'm guessing it won't/can't do this.
> 
> You're right, the RepositoryCopier doesn't contain any protection
> against concurrent changes to the repository. If you allow clients to
> modify the repository while you're backing it up, you may end up with
> an inconsistent backup.

So I have to block those calls while I perform a backup.  That is fine; 
however, I'm wondering why shouldn't I just backup the entire directory 
into a zip file?  Restore would just be replace existing directory with 
the exploded zip.

Am I missing something?  Note: I'm guessing I'd need to shutdown all 
active sessions during a restore, but that is ok as I have control over 
that.

Thanks.

-- 
Samuel Cox

Mime
View raw message