News for hackers. Stuff that matters.
Re:Ask HN: Has anyone ever tried building an OS that doesn't... by captainmuon on Friday September 12, 2014 @03:27PM (#8309939)
BeOS had a nice idea, although it still used files. It's file system doubled as a database, and you could add arbitrary columns to files. For example, contacts were empty files in a special directory, and had attributes like "address", "name" and so on. Mails were also stored in plain files, but unlike mbox/Maildir all the metadata was stored as attributes, not in the files, making it easy to process them with scripts, or to sort them in the file browser.

Its a lot like the never-finished WinFS from Microsoft.

Funnily, modern file systems (extfs3/4, NFTS, HPFS+?) all support extended attributes in some form or another. However, they are currently only rarely used: Mostly for the "this file was downloaded from the internet, do you really want to open it" flag. I wish more programs would use them to store interesting metadata, but it's basically a chicken and egg thing now.

Windows and GNOME also have concepts where you can have calculatable attributes - you have a little library that looks up metadata in a database or parses it from the file, and then serves it as an additional attribute on the file (visible in the file properties tab). You can see it e.g. on mp3s or word documents in windows. However, it doesn't seem to be widely used either, and I wouldn't be surprised if that function has been gutted out of GNOME lately.

Re:Ask HN: Has anyone ever tried building an OS that doesn't... by was_hellbanned on Friday September 12, 2014 @03:35PM (#8309985)
Funnily, modern file systems (extfs3/4, NFTS, HPFS+?) all support extended attributes in some form or another. However, they are currently only rarely used: Mostly for the "this file was downloaded from the internet, do you really want to open it" flag.

For anyone interested in these, they're called Alternate Data Streams in Windows. When you download a file from the Internet, an ADS is created, called "Zone:Identifier", which contains a ZoneID indicating where it came from.

I believe Windows 2000's Explorer allowed the user to add arbitrary tags to any file, and that those were stored in an ADS. For some reason, that was removed in, I think, Windows Vista.

At least one virus stored itself using Alternate Data Streams, which I imagine is related to why they've been more or less downplayed.

Re:Ask HN: Has anyone ever tried building an OS that doesn't... by beloch on Friday September 12, 2014 @03:50PM (#8310073)
I've long wanted metadata fields to help me organize things, but the Achilles heel of systems that use them has always been the lack of standards. I use 2-3 different OS's daily and others less frequently, so I value having the same view of my files no matter where I am. The end result is I just throw everything into the file name.
Re:Ask HN: Has anyone ever tried building an OS that doesn't... by rch on Friday September 12, 2014 @04:07PM (#8310151)
At one point there was a command+database called pq floating somewhere in the plan 9 ecosystem. You'd pass in a path to a resource and it would return a path to the relevant metadata.

http://www.plan9.bell-labs.com/wiki/plan9/using_pq/