Quoth [email protected]:
> Interesting. What's the plumber up to?

Bingo!  The plumber was checking whether /mail/fs/.git was a
directory.  This was due to a plumbing rule I use to visualize commits,
which, at the time of the test, read:

        type is text
        arg isdir $wdir/.git
        data matches '^[0-9a-f]+$'
        plumb start window -dx 1024 -dy 1280 rc -c '''cd '$wdir' ; git/export 
'$0' | vdiff'''

I swapped the isdir and data tests so this rule won't match seemail
messages, and the lock up doesn't happen anymore.  And it explains why
mounting /srv/upasfs.ng in acme's namespace entailed different
behavior.  In that case, /mail/fs wasn't in the plumber namespace so
the isdir test would not interact with upas/fs.  Glad to understand a
bit more what's happening.

This debugging session also highlighted a hidden assumption that I
had, that if a plumbing message had a destination port, it would go to
whoever has that port open for reading, and no rules would be matched.
I see now in plumb(6) that sending the message to the port is the
fallback if no rule matches, quite the opposite of what I'd assumed!
The behavior I was expecting would be ensured by changing the basic
plumbing to the below (just tested).  This seems more sensible to me.

        dst is 'seemail'
        plumb to seemail

There were other hidden assumptions in my original interpretation of
the syscall and stack traces.  (a) I thought Mail would not be able to
receive the seemail message while in doevent(), but I now see that was
wrong; it would receive the message just fine, in its dedicated proc.
Then it would be blocked on sending to the seemail channel until
doevent() returned, but that's fine in this upas+Mail scenario.  (So,
I guess, a properly timed seemail message between the acme Put and
upas's seemail message would cause a similar lock up.) (b) Lastly, I'd
assumed the plumber to be just passing through the bytes, I had
completely abstracted it out!

Thanks for the nudges Ori, much appreciated.

--
Nico


------------------------------------------
9fans: 9fans
Permalink: 
https://9fans.topicbox.com/groups/9fans/T92af154d081c9c25-Mbc0fb0d2275b9701c1100550
Delivery options: https://9fans.topicbox.com/groups/9fans/subscription

Reply via email to