On Wed, Feb 22, 2017 at 04:19:07PM +0800, linbo liao wrote: > Another reason is that I find most thread just discuss modified some > configure, then it just worked, but lack of the reason why it happened.
You have access to the code if needed, it will take less time than collecting possibly outdated threads. And anyway building a test setup is trivial, you just need two listeners and one proxy. You can do everything in a single haproxy config if you need. > I am interesting in the detailed logic about how the stick-table works. Since > If I don't know the logic, I can't make sure my testing cases cover all the > scenario. > > The mainly reason I created this thread is asking for the help about > the internal logic of stick-table. That's exactly what I explained to you. According to what I remember, each new connection which has to track an entry in the stick table needs to take a reference, and if the table is full it will lead to it being first purged before a new one is taken. But if another connection is still using this entry, it may result in the purge not being possible and the new connection to fail to track the table. We used to solve this by having "more" entries. Now I don't remember the exact details and I seem to remember that one specific case was needed for the fail-over case (ie: you don't want that the first connections failing on a dead server update the entry in the table), but for this one I don't remember well. You may find more info in the doc and/or code, and maybe some other persons here have clearer ideas of the specific cases we had to deal with in the past and will be able to explain them better than me. Cheers, Willy

