Re: [PATCH v2] Add ability to select HASH function amongst (SDBM/DJB2/WT6) and optionally apply avalanche

2013-11-14 Thread Willy Tarreau
Hi Bhaskar, On Thu, Nov 14, 2013 at 10:10:44AM -0500, Bhaskar Maddala wrote: > > Worse, when applying consistent hashing on that, only two servers > > got the load for several seconds, then two other ones. > > This is interesting. I did not do a time series distribution in my testing > and this

Re: [PATCH v2] Add ability to select HASH function amongst (SDBM/DJB2/WT6) and optionally apply avalanche

2013-11-14 Thread Bhaskar Maddala
Thank you for your comments, Willy. > 1) "hash algorithm" => I realized that this naming is confusing > because it's used in conjunction with the balance algorithm. > In practice, both the terms "hash algorithm" or "hash function" > are used, with the latter being much more common. So I changed

Re: [PATCH v2] Add ability to select HASH function amongst (SDBM/DJB2/WT6) and optionally apply avalanche

2013-11-14 Thread Willy Tarreau
Hi Bhaskar, OK I'm finally done with this. Having reviewed the existing code allowed me to change my mind on a few points. 1) "hash algorithm" => I realized that this naming is confusing because it's used in conjunction with the balance algorithm. In practice, both the terms "hash algorithm

Re: [PATCH v2] Add ability to select HASH function amongst (SDBM/DJB2/WT6) and optionally apply avalanche

2013-11-14 Thread Willy Tarreau
Hi Bhaskar, I noticed a mistake I'm going to fix. I was a bit bothered by the fact that we had to exclude the hash types from the LB_ALGO while setting a balance algorithm, and realized that the bits you reused for the hash method are themselves covered by BE_LB_ALGO, which is not appropriate sinc

Re: [PATCH v2] Add ability to select HASH function amongst (SDBM/DJB2/WT6) and optionally apply avalanche

2013-11-13 Thread Willy Tarreau
On Wed, Nov 13, 2013 at 03:59:20PM +0100, Willy Tarreau wrote: > On Wed, Nov 13, 2013 at 09:41:31AM -0500, Bhaskar Maddala wrote: > > > 2/4 : > > > - I really like your principle of keeping the default settings > > compatible > > > with current implementations. That said, I still think that s

Re: [PATCH v2] Add ability to select HASH function amongst (SDBM/DJB2/WT6) and optionally apply avalanche

2013-11-13 Thread Willy Tarreau
On Wed, Nov 13, 2013 at 09:46:19AM -0500, Bhaskar Maddala wrote: > Hello Willy, > >I wanted to ask you permission, on whether it was ok to blog about this > change, once it was committed on Tumblr's engineering blog [1]. I can do > so after the changes are in and have your permission on it.

Re: [PATCH v2] Add ability to select HASH function amongst (SDBM/DJB2/WT6) and optionally apply avalanche

2013-11-13 Thread Willy Tarreau
On Wed, Nov 13, 2013 at 09:41:31AM -0500, Bhaskar Maddala wrote: > > 2/4 : > > - I really like your principle of keeping the default settings > compatible > > with current implementations. That said, I still think that since 1.4 > > does not have the full avalanche with consistent hashing

Re: [PATCH v2] Add ability to select HASH function amongst (SDBM/DJB2/WT6) and optionally apply avalanche

2013-11-13 Thread Bhaskar Maddala
Hello Willy, I wanted to ask you permission, on whether it was ok to blog about this change, once it was committed on Tumblr's engineering blog [1]. I can do so after the changes are in and have your permission on it. Thanks Bhaskar [1] http://engineering.tumblr.com/ On Wed, Nov 13, 2013 a

Re: [PATCH v2] Add ability to select HASH function amongst (SDBM/DJB2/WT6) and optionally apply avalanche

2013-11-13 Thread Bhaskar Maddala
Hello Willy, Thanks for your comments, > 1/4 : > - OK in principle. I have rearranged the doc changes in order not to > overrun the 80-column limit. I also found that naming the new flags > BE_LB_HALG_* was clearer than BE_LB_HF_* since they're only used to > define the algorithm. I have

Re: [PATCH v2] Add ability to select HASH function amongst (SDBM/DJB2/WT6) and optionally apply avalanche

2013-11-13 Thread Willy Tarreau
Hi Bhaskar, sorry for the long delay. Yesterday I found some time to come back to your patches. First, I want to thank you for all the well documented work you've done on this subject, that's really great. I'm having some comments, both on the implementation and the code itself. 1/4 : - OK in

Re: [PATCH v2] Add ability to select HASH function amongst (SDBM/DJB2/WT6) and optionally apply avalanche

2013-11-06 Thread Bhaskar Maddala
Hello, I filled in the test result for the remaining cases. It is the same link as before [1]. The tests were executed with 3 data sets as follows (a) 10K requests (includes duplicate host headers) (b) All unique host headers in 1M requests (c) and 250K requests (includes duplicate hosts headers