[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

Re: [PATCH] Implement svnadmin verify --force

From: Julian Foad <julianfoad_at_btopenworld.com>
Date: Thu, 18 Oct 2012 17:41:37 +0100 (BST)

Stefan Sperling wrote:

> Prabhu Gnana Sundar wrote:
>> Currently svnadmin verify would stop verification process once an
>> error/corruption is found in the repo. It does not go till the HEAD
>> of the repo to see if there are further corruptions/errors.
>> It would be helpful if "--force" switch would do this.

> [...] I would prefer an option name such as
> "--continue-on-verification-failure", or... something that sounds a
> bit snappier than that -- but nothing else comes to mind right now :)

GNU Make uses the name '--keep-going' for a similar purpose: "Keep going when some targets can't be made."  That seems like a good choice here.

> Another approach might be to just change the default behaviour instead
> of adding an option. I've never understood why 'svnadmin verify'
> errors
> out once a revision fails. I cannot think of any good reason for this
> behaviour.

In some (many?) kinds of corruption, some or many subsequent revisions also fail to verify just because they reference the corrupted one.  Nevertheless, it's often still helpful to get an idea of how many subsequent revisions verify OK even in those cases.  In practice, when examining a corrupted repository, I have usually started by running "svnadmin verify" on one revision at a time, in a loop, to get the effect of a 'keep-going' option.

So I agree it could be a sensible option to just do this by default.  We would need to be careful to make sure the final exit status is non-zero, and that a clear message is printed indicating that errors were found, in case the admin just sees the last screen full of "Verified OK" messages and wrongly assumes the complete verification was OK.

- Julian
Received on 2012-10-18 18:42:23 CEST

This is an archived mail posted to the Subversion Dev mailing list.