From mboxrd@z Thu Jan 1 00:00:00 1970 MIME-Version: 1.0 References: <36c9016b7918c302d777f1a605fc107f@brasstown.quanstro.net> <2CBEED8D-800D-40C8-8182-162695D9FF30@9srv.net> <45fe7ac7a1dab989624aa4ed2b376ff9@brasstown.quanstro.net> From: Skip Tavakkolian Date: Wed, 4 Feb 2015 16:30:15 +0000 Message-ID: To: Fans of the OS Plan 9 from Bell Labs <9fans@9fans.net> Content-Type: multipart/alternative; boundary=001a1139f848ce4f94050e45b35a Subject: Re: [9fans] wstat and atomic directory change Topicbox-Message-UUID: 4004d8c4-ead9-11e9-9d60-3106f5b1d025 --001a1139f848ce4f94050e45b35a Content-Type: text/plain; charset=UTF-8 you can consider doing it out of band; e.g. a new fossil console command. On Wed, Feb 4, 2015 at 6:30 AM Giacomo Tesio wrote: > And unfortunately I cannot figure out any alternative, either. :-( > > An interesting point is: why directory entries can be read but cannot be > written? I mean we use Tcreate to create a new file in a dir, while to be > uniform with files, we should use a Twrite, appending a corresponding stat > structure at the end of a directory entry. > > However this solution probably has not been adopted to enable safe > concurrency in the file creation and removal. > > However this asymmetry shows that directories cannot be (pratically) > handled in the same way of files. > > > Giacomo > > > 2015-02-04 15:06 GMT+01:00 erik quanstrom : > >> > You are right. >> > But since protocol customizations goes against that same ideal, what's >> the >> > plan9 way of dealing with a feature X (in this specific case atomic file >> > moves)? >> > >> > >> > > this requires delving into the namespace to tell that the directories >> are >> > > still under the >> > > same mount, and some non-uniform operations. >> > > >> > >> > Good point. But thus, what are the alternatives? >> >> i wasn't holding out. i don't have any suggestions. >> >> - erik >> >> > --001a1139f848ce4f94050e45b35a Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable you can consider doing it out of band; e.g. a new fossil console command.
On Wed, Feb 4, 2015 at 6:30 AM Giacomo Tesio &= lt;giacomo@tesio.it> wrote:
<= blockquote class=3D"gmail_quote" style=3D"margin:0 0 0 .8ex;border-left:1px= #ccc solid;padding-left:1ex">
And unfortunately I cannot f= igure out any alternative, either. :-(

An interesting po= int is: why directory entries can be read but cannot be written? I mean we = use Tcreate to create a new file in a dir, while to be uniform with files, = we should use a Twrite, appending a corresponding stat structure at the end= of a directory entry.

However this solution proba= bly has not been adopted to enable safe concurrency in the file creation an= d removal.=C2=A0

However this asymmetry shows that= directories cannot be (pratically) handled in the same way of files.
=


Giacomo


= 2015-02-04 15:06 GMT+01:00 erik quanstrom <quanstro@quanstro.net&g= t;:
> You are right.
> But since protocol customizations goes against that same ideal, what&#= 39;s the
> plan9 way of dealing with a feature X (in this specific case atomic fi= le
> moves)?
>
>
> > this requires delving into the namespace to tell that the directo= ries are
> > still under the
> > same mount, and some non-uniform operations.
> >
>
> Good point. But thus, what are the alternatives?

i wasn't holding out.=C2=A0 i don't have any suggestions.
- erik


--001a1139f848ce4f94050e45b35a--