News for hackers. Stuff that matters.
Re:Rob Pike comments on Ryan Dahl's rant by p9idf on Wednesday October 05, 2011 @04:49PM (#3077504)
Plan 9 uses a system called notes in place of Unix signals. It's pretty much the same idea, but instead of sending an integer you can send arbitrary strings by writing to /proc/n/note. Non-trappable messages are sent to /proc/n/ctl.

This is a more flexible system than Unix integer signals, but in practice the extra flexibility isn't often used, as a process can simply mount a ctl file into the namespace or post a pipe in /srv.

http://plan9.bell-labs.com/magic/man2html?man=proc&sect=...

http://plan9.bell-labs.com/magic/man2html?man=srv&sect=3

Re:Rob Pike comments on Ryan Dahl's rant by jimktrains2 on Wednesday October 05, 2011 @09:25PM (#3078588)
I always thought it'd be cool if all programs implemented external apis this way. Kind of like how applescript works, but, for a mail program, for instance, write "Hacker News" to /proc/n/query and it'd return the data. Or write 'message 1' to /proc/n/open and it'd open or return it.
Re:Rob Pike comments on Ryan Dahl's rant by p9idf on Wednesday October 05, 2011 @09:55PM (#3078690)
You wouldn't put those sorts of things in /proc, but that's basically how things work. And since it's a filesystem, you can export your API effortlessly over the network.

http://plan9.bell-labs.com/magic/man2html/4/upasfs

http://plan9.bell-labs.com/magic/man2html/4/webfs

Re:Rob Pike comments on Ryan Dahl's rant by jimktrains2 on Thursday October 06, 2011 @11:40AM (#3080474)
I imagined them in proc because i imaged them being exported by the application.

Reading your links now.

Edit: Yeah, that's pretty much what I was envisioning. I need to play with plan9 more:-\