[Redis] DEV release with new network code

Pavel Shaydo pshajdo at gmail.com
Sun Apr 27 09:27:55 GMT 2014


On Sat, 26 Apr 2014 09:38:52 -0700
Damien Krotkine <damien at krotkine.com> wrote:
> I've juste released Redis-1.973_01, it's a DEV release with the new
> network code from Ivan. Basically it now uses sysread instead of
> readline. I hope cpantesters results will be good enough.
> 
> If you have the opportunity, please install this version and test it,
> especially in situation where latency and/or speed performance is
> needed, as I would like to make sure the performances are the same or
> better, before releasing a real version

Performance is seems about the same. Glancing throw the code I see
you're using MSG_DONTWAIT which is not available on Windows, AFAIK. The
whole __try_read_sock subroutine looks a bit inefficient to me, you are
reading data with MSG_PEEK, just to check if there's any, and then you
throwing it away. Why not save it into {__buf} and avoid reading it
again? It is especially strike the eye in this loop:

https://metacpan.org/source/DAMS/Redis-1.973_01/lib/Redis.pm#L428

Pavel Shaydo



More information about the Redis mailing list