Hi,
Has anyone done work on writing a "transport" module for messages with
Event.pm? I mean something along the lines of Sriram Srinivasan's
Msg.pm [1], but using Event's event loop rather than one of it's own.
The nice thing about such a module is that it handles reassembly of
possibly fragmented messages on its own, and leaves the application
with the need of only caring about the application-level protocol.
I see three variants of Msg.pm that could be useful:
- Length-prepended, arbitrary-size messages (the current Msg.pm)
- Line-based messages (very simple to use, even when the other end
doesn't know it's talking with a special module)
- Fixed-length messages (with some sort of prior negotiation on message
length)
If someone has a sort-of-a-port written, I'd love to have a copy. If not,
I'd like to help in writing one myself. But I want suggestions on how to
do it: should this be part of the Event kit, or a statndalone module that
merely depends on Event? Any particular issues I should have in mind when
writing this?
Thanks in advance,
Gaal
[1] Described in his book, _Advanced Perl Programming_. O'Reilly, 1997.
Module available via CPAN or ftp.ora.com .
--
believing is seeing
[EMAIL PROTECTED]
http://www.forum2.org/gaal/