gautam has asked for the wisdom of the Perl Monks concerning the following question:
I find during stress testing that I'm missing some syslogs(roughly 5%). I'm assuming this is because of the time taken to process the statements after the recv().my $MySocket=new IO::Socket::INET->new(LocalPort=>$listenport,Proto=>' +udp'); while(1) { #receive syslog $MySocket->recv(my $text,1500); #some logging statements #put it in a queue $MyQueue->enqueue($text); }
I think receiving the syslog and enqueing it in the same line of code would help. Any ideas on how to go about this? Any suggestions/comments are welcome.
Thanks in advance
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Need help with Socket recv
by aquarium (Curate) on Mar 29, 2006 at 14:55 UTC | |
by gautam (Initiate) on Mar 30, 2006 at 08:10 UTC | |
|
Re: Need help with Socket recv
by traveler (Parson) on Mar 29, 2006 at 15:44 UTC | |
by gautam (Initiate) on Mar 30, 2006 at 08:12 UTC | |
by traveler (Parson) on Mar 30, 2006 at 23:51 UTC | |
|
Reduced the UDP Socket packet drops by increasing buffer size
by gautam (Initiate) on Mar 30, 2006 at 11:24 UTC |