On Mar 21, 2009, at 12:00 AM, Roman Shaposhnik wrote:
I could swear that I remember the following question being asked
during
the times when 9P2000 was being introduced, but I simply can't find
any relevant threads. I do apologize if my google-foo is failing me,
but here it goes: what is the reason for not allowing writes to the
directories (with the append-only semantics and stat structures
payloads, of course)?
Is it simply because since we can't really get rid of create (because
of the transactional nature of create-open) it was deemed to be
unimportant to have directory writing semantics or was there a
subtler reason that I can't fully recall.
No takers, huh? Well, may be a bit of background would help so that
the question doesn't sound as a purely navel-gazing exercise.
The story here is that we are building a bunch of RESTful APIs
and my personal preference is to bend HTTP as close to 9P
as I can get (for obvious reasons). Now, the closest match
to "create" would be POST with a metadata payload on a
"subdirectory" URI. But of course, it is not a create at all.
It really is much closer to write on a subdirectory. Hence the
question: is there anything that HTTP makes us lose except
for the transactional nature of create?
Thanks,
Roman.