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

Re: Pre-commit transaction modification question

From: Philip Martin <philip_at_codematters.co.uk>
Date: 2004-02-12 04:03:58 CET

David Ripton <dripton@ripton.net> writes:

> Is it okay if a checkin generates two versions of a badly formatted
> source file, the ugly one exactly as checked in by the user and then a
> clean one?

It's OK for the post-commit to trigger another commit, but there are
some complications.

  1/ The post-commit is asynchronous so there is a race:
     - R1 commit completes
     - R1-post-commit starts building a commit R1'
     - R2 commit completes
     - R1' attempts to complete but may fail due to R2

  2/ You need to take care to avoid loops. It's probably a good idea
     to take steps to ensure that any "automatic" commits triggered by
     a post-commit cannot trigger another "automatic" commit. Perhaps
     by using a separate user ID for the automatic commits and have
     the post-commit ignore commits by that user.

Philip Martin
To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
For additional commands, e-mail: users-help@subversion.tigris.org
Received on Tue Mar 9 00:13:01 2004

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