Thoughts on file ids

Jelmer Vernooij jelmer at samba.org
Tue May 3 14:35:52 UTC 2011


File ids have a couple of known issues; in particular (my pet peeve)
they make parallel imports very problematic. They're also hard on
foreign branch implementations which don't natively have the concept of
file ids. And they're a blocker for file copies.

File ids currently seem to serve three fairly distinct purposes:

1) as ways to get at files in the tree API

2) as part of the keys to look up texts

3) as a way to determine equivalent files between different trees in
merges

As far as I can tell there is nothing in the API that should really
require the file identifiers in these three cases to be identical, and
these three use cases have distinct requirements:
]
(1) and (2) strictly require file ids to be unique and refer to one
specific file/path. (3) in theory doesn't, although the current
implementation probably does.

(2) requires file ids to be persistent across multiple runs of bzr. (3)
doesn't - (1) probably doesn't, depending on whether we allow external
users to access files by file id.

(2) seems like it could be a repository implementation detail, and not
something that needs to be exposed at the API level.   

Jelmer 
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 836 bytes
Desc: This is a digitally signed message part
URL: <https://lists.ubuntu.com/archives/bazaar/attachments/20110503/dc32d2a9/attachment.pgp>


More information about the bazaar mailing list