in reply to Re^6: Forking Clients
in thread Forking Clients
If you only need to know that the spawned process is complete, then that's pretty easy. A non-blocking wait could help with that if you plan on rolling your own.
If, however, the main program needs to know what's going on in the spawned processes then you have a more complicated issue.
I recommend you get and read a book by Stevens. Perhaps UNIX Network Programming, Volume 2, Second Edition: Interprocess Communications, Prentice Hall, 1999 (ISBN 0130810819) or maybe Advanced Programming in the UNIX Environment, Addison-Wesley, 1992 (ISBN 0201563177).
Before you protest that you're not programming in C or that you're not using Unix, let me point out that the concepts are the same. The Unix family of OSes is the home of sockets, C, Perl, several forms of IPC, regular expressions as a computational tool, and more. Perl borrows heavily from C, Unix, and Unix-borne tools in its concepts. If you know Perl and how IPC works on Unix, then save for a few caveats about other OSes you're mostly set to do IPC in Perl.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^8: Forking Clients
by gepapa (Acolyte) on Oct 16, 2008 at 12:31 UTC | |
by mr_mischief (Monsignor) on Oct 16, 2008 at 19:30 UTC |