[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: mod_lisp for guile
From: |
Neil Jerram |
Subject: |
Re: mod_lisp for guile |
Date: |
Thu, 29 Dec 2005 10:18:34 +0000 |
User-agent: |
Gnus/5.1007 (Gnus v5.10.7) Emacs/21.4 (gnu/linux) |
Alan Grover <address@hidden> writes:
> Could you talk a little bit more about the "select with other stuff"
> pattern? What kind of stuff?
Yes, here are two examples.
1. In gds-server.scm in guile-debugging, I have a process that needs
to accept both TCP connections from Guile client processes, and
protocol instructions on its standard input from Emacs. So I
manage all this by selecting on (i) standard input, (ii) the TCP
server socket, (iii) all the TCP connection sockets.
2. In another project X, I have an instance of X which acts as a
central management point for several other instances of X, and
which can itself be controlled through a web interface. The
central X handles all its possible inputs by selecting on both the
web server socket and the sockets to the other Xs.
Do these help? Please let me know if they're not clear enough.
I might be able to avoid these selects by using threads, but I've
acquired a preference for doing things this way. In my experience
threads are more difficult to debug, and their implementation across
platforms is patchy.
Regards,
Neil