HTTP-404 has asked for the wisdom of the Perl Monks concerning the following question:

Guys where can i find Tutorials on Writing servers (IO::Socket) Thank You very much

Replies are listed 'Best First'.
Re: Tutorials on Writing servers
by archon (Monk) on Mar 21, 2001 at 02:46 UTC
    Depends what kind of server you're writing. If you want to handle the networking with your server, you can use the example in the IO::Socket manpage:
    $sock = IO::Socket::INET->new(Listen => 5, LocalAddr => 'localhost', LocalPort => 9000, Proto => 'tcp');
    and then read from $sock.

    If you are on *ix, you can have the OS handle the networking for you by using inetd.

    I don't know of any generic 'server' tutorials, but if you are stuck at a particular point that could make a better question.

Re: Tutorials on Writing servers
by merlyn (Sage) on Mar 21, 2001 at 04:18 UTC
Re: Tutorials on Writing servers
by Corion (Patriarch) on Mar 21, 2001 at 02:53 UTC

    If you've mastered the examples in the IO::Socket documentation, you might want to go the easy route of prepackaged server models, as Net::Server has it.

    The documentation claims that Net::Server implements many server models as subclasses, inetd-style servers, single-process (forking or singleton) servers and even preforking servers (like Apache). I don't know how accessible the module is to somebody who dosen't have much experience with writing his own server though. The Net::Server framework is also relatively fresh, this might be another obstacle you want to avoid. On Perlmonks there also are some small server implementations, I'll plug mine : here

      thank you