extended attribute standardization

Vegard Nossum vegard at peltkore.net
Sun Nov 19 19:22:29 EET 2006

On Thu, November 16, 2006 5:22 pm, Joe Shaw wrote:
> On Thu, 2006-11-16 at 02:31 +0100, Vegard Nossum wrote:
>> I would like to propose a more formal discussion around the
>> standarization
>> of attribute names and usage, which could eventually lead to a draft or
>> memo of sorts (freedesktop standard, RFC, etc).
> I think the idea is a good one, but I feel that it's somewhat premature
> to create a big deal around something that virtually nobody uses at this
> point.  It's up for application developers to decide how they want to
> use extended attributes, and it's been my experience that trying to
> define standards before there are any real users or use-cases ultimately
> leads to an incomplete and ineffectual document.

The problem with letting everybody use attributes in their own way, is
that programs cannot benefit from the metadata that other programs store.
Even something as trivial as storing an attribute with a different
capitalization can make it useless for other programs.

Part of the project would also be to develop patches for applications that
are already in use. A purpose of the informal standard document would be
to ensure that most or all of these programs/patches are compatible with
each other. The guidelines should not enforce, but be flexible; new
programs or patches with new requirements could influence current
practices. Keeping xattrs-in-programs development in a single repository
enables the programs to stay in touch with each others and the standard.

What I would like to discuss and later put in writing are actually rather
simple things. I think, for instance, that it would be useful to store
arrays of information in extended attributes (think of a file history of
source URIs whenever a file is copied or moved). Storing an array would
require some kind of encoding where each element is separated by
semicolons. Now there must be a way of storing semicolons in the elements
themselves, so there must be an escape sequence for semicolons. This is
not a very complicated concept in itself, but different people come up
with different solutions (which may or may not be equally good). I think
that discussing these things and writing them down will benefit
programmers in the future.

> Beagle's uses of extended attributes are largely for its own internal
> accounting.  They tell us whether the file has been indexed and if the
> index representation is up to date.

Yep. I thought they were actually indexing the metadata itself. My mistake :)

> Deciding how best to use xattrs and advocating their use with other
> developers seems like a more important first step than setting up wikis
> and mailing lists.

Okay. I'll chew on it, probably make some more posts to xdg, and see if we
can decide on something. Thanks for your interest :)

Kind regards,

More information about the xdg mailing list