Skip Menu |
 

This queue is for tickets about the Sys-Syslog CPAN distribution.

Report information
The Basics
Id: 34753
Status: resolved
Priority: 0/
Queue: Sys-Syslog

People
Owner: SAPER [...] cpan.org
Requestors: powerman [...] powerman.name
Cc:
AdminCc:

Bug Information
Severity: Unimportant
Broken in:
  • 0.19
  • 0.20
  • 0.21
  • 0.22
  • 0.23
  • 0.24
Fixed in: 0.25



Subject: Sys-Syslog 0.19-0.24 slowdown
Date: Tue, 8 Apr 2008 02:04:12 +0300
To: bug-Sys-Syslog [...] rt.cpan.org
From: Alex Efros <powerman [...] powerman.name>
Download (untitled) / with headers
text/plain 1007b
Hi! I'm using socklog (syslog-compatible log daemon) for logging in my projects, i.e. each project run own socklog daemon, and have own unix socket to send logs to that daemon. So, I HAVE to use setlogsock('unix'). Starting from version 0.19 there was 0.25 sec timeout added in connection_ok(): - my $ret = select $rin, undef, $rin, 0; + my $ret = select $rin, undef, $rin, 0.25; I've no idea about reason to do this (at least I don't find anything related to this in Changelog or documentation), but this have side effect in slowing down logging. For example, I've fast networking I/O code which doing thousands operations on non-blocking sockets every second, and I wish to log a lot of messages every second (may be thousands too, in debug mode). But after 0.25 sec timeout was added, I can log 4 messages per second maximum! This isn't acceptable, so for now I stick to 0.18. Can you explain reason why that timeout needed and make it possible to disable (or configure) it? -- WBR, Alex.
Subject: Re: [rt.cpan.org #34753] Sys-Syslog 0.19-0.24 slowdown
Date: Tue, 8 Apr 2008 02:05:14 +0200
To: bug-Sys-Syslog [...] rt.cpan.org
From: Sébastien Aperghis-Tramoni <saper [...] cpan.org>
Download (untitled) / with headers
text/plain 1.9k
Alex Efros wrote: Show quoted text
> Hi!
Hello, Show quoted text
> I'm using socklog (syslog-compatible log daemon) for logging in my > projects, i.e. each project run own socklog daemon, and have own unix > socket to send logs to that daemon. So, I HAVE to use setlogsock > ('unix').
I guess this means you've read the documentation and now what you're doing, which is good (most people are just cargo-culting without knowing). Show quoted text
> Starting from version 0.19 there was 0.25 sec timeout added in > connection_ok(): > - my $ret = select $rin, undef, $rin, 0; > + my $ret = select $rin, undef, $rin, 0.25; > > I've no idea about reason to do this (at least I don't find anything > related to this in Changelog or documentation), but this have side > effect > in slowing down logging. For example, I've fast networking I/O code > which > doing thousands operations on non-blocking sockets every second, and I > wish to log a lot of messages every second (may be thousands too, > in debug > mode). But after 0.25 sec timeout was added, I can log 4 messages per > second maximum! This isn't acceptable, so for now I stick to 0.18. > > Can you explain reason why that timeout needed and make it possible to > disable (or configure) it?
I have no memory of why this was changed. Thanks goodness we have revision control system. Sys-Syslog' SVN tells me that this line was changed in décember 2006: » http://svnweb.mongueurs.net/Sys-Syslog/revision/?rev=62 Finding the actual reason was a little more tough, because there wasn't any direct mail from these people to me, but I finally found it: » http://london.pm.org/pipermail/london.pm/Week-of- Mon-20061211/005961.html I agree adding it without checking the running operating system was probably a bad idea. What I can do is to permit one to set the timeout via a third argument to setlogsock(), roll back to the default value of zero on all systems except on OSX where it is then set to 0.25 sec. -- Sébastien Aperghis-Tramoni Close the world, txEn eht nepO.
Subject: Re: [rt.cpan.org #34753] Sys-Syslog 0.19-0.24 slowdown
Date: Tue, 8 Apr 2008 03:34:21 +0300
To: S??bastien Aperghis-Tramoni via RT <bug-Sys-Syslog [...] rt.cpan.org>
From: Alex Efros <powerman [...] powerman.name>
Download (untitled) / with headers
text/plain 332b
Hi! On Mon, Apr 07, 2008 at 08:06:22PM -0400, S??bastien Aperghis-Tramoni via RT wrote: Show quoted text
> What I can do is to permit one to set the timeout via a third > argument to setlogsock(), roll back to the default value of zero on > all systems except on OSX where it is then set to 0.25 sec.
Sounds good for me. :) -- WBR, Alex.
Subject: Re: [rt.cpan.org #34753] Sys-Syslog 0.19-0.24 slowdown
Date: Sun, 20 Apr 2008 03:52:20 +0200
To: bug-Sys-Syslog [...] rt.cpan.org
From: Sébastien Aperghis-Tramoni <saper [...] cpan.org>
Download (untitled) / with headers
text/plain 577b
Alex Efros wrote: Show quoted text
> Sébastien Aperghis-Tramoni via RT wrote:
>> What I can do is to permit one to set the timeout via a third >> argument to setlogsock(), roll back to the default value of zero on >> all systems except on OSX where it is then set to 0.25 sec.
> > Sounds good for me. :)
This is committed in the SVN. You may also be interested in a change I made to setlogsock() which allows to set the remote host for network mechanism with the second argument: setlogsock("udp", $remotehost); -- Sébastien Aperghis-Tramoni Close the world, txEn eht nepO.
Subject: Re: [rt.cpan.org #34753] Sys-Syslog 0.19-0.24 slowdown
Date: Sun, 8 Jun 2008 03:09:50 +0200
To: bug-Sys-Syslog [...] rt.cpan.org
From: Sébastien Aperghis-Tramoni <maddingue [...] free.fr>
Download (untitled) / with headers
text/plain 130b
This issue is fixed in version 0.25. Thanks for your report. -- Sébastien Aperghis-Tramoni Close the world, txEn eht nepO.


This service is sponsored and maintained by Best Practical Solutions and runs on Perl.org infrastructure.

Please report any issues with rt.cpan.org to rt-cpan-admin@bestpractical.com.