Concerning Re: Rename: data loss
Ben Collins-Sussman wrote on 8 Sep 2003, 7:34, at least in part:
> "Sindbad the Seafarer" <sindbad.the.seafarer@gmx.net> writes:
>
> > Now I only wonder what would have happened if wc1/file1 with the
> > added paragraph had been already committed before
> > wc2/renamedfile1? Would then the added paragraph in file1 had
> > been merged into renamedfile1? (I simply have nothing around
> > today to just try it.)
>
> Well, the person doing the name would have a "copy" and "delete"
> scheduled in the their working copy. When they try to commit, the
> 'delete' of file1 would fail, because their copy would be officially
> out-of-date (it doesn't have the added paragraph).
>
> So in response, the 2nd user runs 'svn up'. The receive a patch to
> the schedule-delete file. At this point, they may have second
> thoughts about committing. If they commit the "deletion and copy",
> they'll be committing the deletion of the "new" file1 text, whereas
> the copy will still be of the "old" file1. So yah, a commit would
> result in the loss of the new paragraph.
>
> Again, in an ideal situation, 'svn up' should add the paragraph not to
> the schedule-delete file, but to the schedule-copy one. But that
> won't happen until we have atomic move operations someday.
So for now the lesson is A) to commit often; B) to update just
before doing such drastic things like renaming and deleting and
then directly commit renamed/deleted files.
Though this cannot guarantee that such situations do not come up
at all it can reduce the chance of them.
Perhaps I have to rethink our commit policy here. Dunno how this
is on programming, but with website production it seemed fine to
update in the morning and commit in the evening, with more cycles
only if there had been site-wide changes involving many files.
Jan Hendrik
---------------------------------------
Freedom quote:
Welfare's purpose should be to eliminate,
as far as possible, the need for its own existence.
-- Ronald Reagan, Los Angeles Times, January 7, 1970
---------------------------------------
Mailed with Pegasus Mail 3.12c (32bit).
Never heard of it?
Easy to use, full featured - and freely available.
And *no* automatic virus activation and spreading.
Take a look at http://www.pmail.com
Give it a try - and you'll never miss anything else.
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
For additional commands, e-mail: users-help@subversion.tigris.org
Received on Tue Sep 9 09:02:29 2003