[merge] remove SFTPLock and support for weaves over SFTP
mbp at canonical.com
mbp at canonical.com
Mon Jan 26 20:13:25 GMT 2009
On 26/01/2009, John Arbash Meinel <john at arbash-meinel.com> wrote:
> So IIRC, Weave repos used an OS lock, but for SFTP access we created a
> file with O_EXCL. Which meant that locking over SFTP was not actually
> lock-safe versus local access. (It was safe versus another SFTP access,
> which was, in general, good enough, but we went a different route to be
> truly safe against all forms of access.)
That is correct, and of course the new locks also handle stale locks
and breaking locks a bit better.
> So I'm happy to remove it, though it might be nice to have a good error
> of "cannot access Weave repositories over sftp" somewhere.
That's true, this error will be a bit cryptic, but it should always
follow a message about the format being deprecated and that upgrade
should be used, like this:
Format <RepositoryFormat6> for sftp://localhost/tmp/a/.bzr/ is
deprecated - please use 'bzr upgrade' to get better performance
bzr: ERROR: Transport operation not possible: transport locks not
supported on sftp://localhost/tmp/a/.bzr/branch-lock
Given we've been sending that warning for more than a year now iirc
maybe it's enough, but I can add more if you think it's needed.
> What brought this up, btw?
I was coming back to sftp to finish adding transport activity
indicators, and noticed some of the cruft, therefore sent this and the
other series of patches.
I think the way we do reviews, and the way we handle format and API
backward compatibility does tend to leave old code around for a long
time. That compatibility has value, but old unused code does make
things seem larger, and may affect load time. So, I like to clean it
out eventually.
Here's an updated patch that also removes it from ftp and just relies
on the implementations in the base class.
--
Martin <http://launchpad.net/~mbp/>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 20090126-remove-sftplock-2.diff
Type: text/x-diff
Size: 16777 bytes
Desc: not available
Url : https://lists.ubuntu.com/archives/bazaar/attachments/20090126/c527d88a/attachment-0001.bin
More information about the bazaar
mailing list