Thanks for testing. I checked, scripts run OK indefinitely long with Windows Server 2008, where real application is supposed to run. The failure occurs at old 32 bit WinXP, where I have a copy for tests and development. So, false alarm, sorry. Perl is Strawberry 5.24 both, + latest modules

Update. Still, something strange is happening. Let now "server" be as simple as:

use strict; use warnings; use IO::Socket::INET; my $PORT = 53123; my $num = 0; my $sock = new IO::Socket::INET( LocalHost => '127.0.0.1', LocalPort => $PORT, Proto => 'tcp', Listen => 5, Reuse => 1, ) or die; binmode $sock; while ( my $client = $sock-> accept ) { my $str = do { local $/; <$client> }; die "$num\n" unless $str eq '123'; print "$num\n" unless $num ++ % 1000; }

And worker:

use strict; use warnings; use autodie; use IO::Socket::INET; my $PORT = 53123; while () { my $sock = new IO::Socket::INET( PeerHost => '127.0.0.1', PeerPort => $PORT, Proto => 'tcp', ) or die; binmode $sock; print $sock '123'; $sock-> close; select( undef, undef, undef, 0.01 ) }

Again, runs OK indefinitely long with Windows Server 2008, 64-bit Perl. And rarely does it go past a few thousands in WinXP, in:

This is perl 5, version 24, subversion 0 (v5.24.0) built for MSWin32-x86-multi-thread-64int

Which is somewhat disturbing. Is this my machine / installation somehow broken? Can't believe it's Perl issue. For not so long ago 32-bit OS (Windows i.e.) and 32-bit Perl were common.


In reply to Re^2: Problem with IO::Async application (Updated) by vr
in thread Problem with IO::Async application by vr

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.