in reply to Chat server impossible with Perl?
But if you want concurrency, look at POE. Pretty easy to "appear" to do things simultaneously there, sharing the data structures needed. In fact, there's already an IRC server framework there, so you could use standard IRC clients with your "server".
If you insist on coding from scratch, you can have your child processes communicate via some lightweight database, like DBM::Deep or DBD::SQLite. It'd be pretty simple to write a classic "fork on accept" server that then uses the database to keep in touch with other children to share the chat info. Probably have to use a timed-out read loop to go check the database from time to time.
-- Randal L. Schwartz, Perl hacker
Be sure to read my standard disclaimer if this is a reply.
|
---|
Replies are listed 'Best First'. | |
---|---|
Re^2: Chat server impossible with Perl?
by belden (Friar) on Feb 04, 2005 at 22:17 UTC |