9fans - fans of the OS Plan 9 from Bell Labs
 help / color / mirror / Atom feed
From: andrey mirtchovski <mirtchovski@gmail.com>
To: Fans of the OS Plan 9 from Bell Labs <9fans@9fans.net>
Subject: Re: [9fans] Different representations of the same file/resource in a synthetic FS
Date: Tue,  9 Jun 2009 11:27:26 -0600	[thread overview]
Message-ID: <14ec7b180906091027g4c060b5egf0e15265289e5ee6@mail.gmail.com> (raw)
In-Reply-To: <1244567653.9958.1733.camel@work>

I think I've mentioned this before, but on a few of my synthetic file
systems here I'm using what you describe to slice a database by
specific orderings. For example, I have a (long) list of resources
which I'm managing in a particular environment each has an owner,
type, status and a few static data containers. It's all backed by a
relational database, but the file server presents different "slices"
of that to external users, where the directory structure is rigidly
defined as:

/
 available/
 by-type/
 by-owner/
 inuse/
 ...

with all data to fill the directories being dynamically pulled from
the database.

in this particular case it saves me having to implement a generic SQL
query mechanism, which is unsafe, as well as pushing the complexity of
knowing the underlying database structure onto the clients. in the
end, clients only know how to navigate to a particular resource and
'reserve' or 'release' it. this scheme could potentially be extended
(at least in my case) to match your "user-defined sets" by simply
enumerating every unique column in the database as subdirectories. a
user defines a "subset" of all available nodes of a particular type
foo which have owner bar by cd-ing to
/available/by-type/foo/by-owner/bar. (I admit this is a bit hasty, so
perhaps not what you're really after)...

the reason i'm sticking with a file system is that if i have to do
this for many different resources which can't  be easily stuck in the
same database, I'd have to design a protocol in order to avoid
replicating everything, and if I'm going to design a protocol I may as
well use 9p, something that's simple and I'm familiar with.



  reply	other threads:[~2009-06-09 17:27 UTC|newest]

Thread overview: 19+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-06-09 17:14 Roman V Shaposhnik
2009-06-09 17:27 ` andrey mirtchovski [this message]
2009-06-09 18:10   ` erik quanstrom
2009-06-09 19:01     ` andrey mirtchovski
2009-06-11  3:44   ` Roman V. Shaposhnik
2009-06-11  4:49     ` [9fans] Different representations of the same lucio
2009-06-13  1:02       ` Roman V Shaposhnik
2009-06-13  1:56         ` erik quanstrom
2009-06-16 23:12           ` Roman V Shaposhnik
2009-06-17  8:54             ` Charles Forsyth
2009-06-18  0:20               ` Roman V Shaposhnik
2009-06-13  3:43         ` lucio
2009-06-16 23:15           ` Roman V Shaposhnik
2009-06-09 17:30 ` [9fans] Different representations of the same file/resource in a synthetic FS J.R. Mauro
2009-06-09 18:15 Francisco J Ballesteros
2009-06-09 18:59 erik quanstrom
2009-06-09 19:16 erik quanstrom
     [not found] <eed9f9e37182c89c3e8a9982844f9d0f@quanstro.net>
2009-06-09 19:31 ` andrey mirtchovski
2009-06-09 19:41 erik quanstrom

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=14ec7b180906091027g4c060b5egf0e15265289e5ee6@mail.gmail.com \
    --to=mirtchovski@gmail.com \
    --cc=9fans@9fans.net \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).