Hi Aleks, On Thu, Apr 02, 2015 at 03:39:27PM +0200, Aleksandar Lazic wrote: (...) > I think it would be worth to check how much time costs to switch from > c to lua and back.
I already tried. On my laptop I was seeing 55k conn/s on a simple test which was building a redirect from a sample fetch declared in Lua which was concatenating 3 other fetch results and calling crc32 on them. I did it just for fun and was pleased to see that the overhead is very low. (...) > But as every time then comes the Users and say haproxy is slow because > there LUA-Script is full of flaws ;-/ This is inevitable. Several years ago, I've seen people saturate an F5-8800 with just a few hundreds of requests per second while this device was supposed to be capable of hundreds of thousands, just because they completely filled the machine with thousands of iRules. I was disgusted just by thinking about it... ordering a machine designed for high traffic, involving hardware accelerators for L4/SSL, just to immediately set a bottleneck using a massive amount of L7 rules is absurd. I would have liked to exchange it for a PC running haproxy to resell it later and get rich, but they preferred to upgrade it. Some people like to use the wrong tool for a given job, just because it's possible. So we'll see it as well with haproxy/lua (and we'll be able to point them to this thread). BTW the absolute record I've seen in a real configuration for haproxy was 450000 named ACLs and their respective use_backend rules to implement geolocation by hand! It did not run very fast to be honnest, just enough for a medium site :-) Cheers, Willy

