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

Re: Extended Attribute Support (was Re: Mac OS X "resource fork" support)

From: Ph. Marek <philipp.marek_at_bmlv.gv.at>
Date: 2005-08-17 07:31:09 CEST

Regarding the way resource forks and xattrs could be done in the repository
I'd like to present an idea.

First I assume the standard layout in the repository -
        /trunk
        /tags
        /branches

Then there is some file, say
        /trunk/dir/file

When this gets committed from a resource-fork-aware machine, the pathname in
the repository gets hashed to a md5-sum:
        $ echo -n "/trunk/dir/file" | md5sum
        71523811009e11f8674bda76bfe2bc93

So a complete tree of forks/attributes can be stored in eg.
        /macos-resource-forks/71/52/3811009e11f8674bda76bfe2bc93/

And this path gets stored as an attribute to the file.
        svn:mac-os-rf=/macos-resource-forks/71/52/3811009e11f8674bda76bfe2bc93/

Advantages:
- simple, clean model
- only client changes required
- attributes are still small entities
- we can store arbitrary large, versioned attribute trees -
        svn:xattr=/xattr-resources/71/52/3811009e11f8674bda76bfe2bc93/
- on tag/branch creation, the attribute pointing to other data gets copied.
  *But* as soon as another version is committed, the path in the repository
  is different, so the hash is different, so a new rf directory gets started
  (possibly a copy of the old).
- Non-resource-fork aware machines have only a vanishingly small penalty.
  (Similar for xattr)

Comments??

Regards,

Phil

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Wed Aug 17 07:32:09 2005

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

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.