----------------original message-----------------
De: "Milo? Koz�k" milos.ko...@lejmr.com
A: haproxy@formilux.org
Date: Thu, 24 Sep 2015 08:21:48 +0200
-------------------------------------------------
 
 
> Any thoughts?
> 
> Dne 22.9.2015 v 09:35 Milo? Koz�k napsal(a):
>>
>> Hi,
>>
>> I am trying to set up a load balancer for a special binary protocol 
>> which uses TCP for transport. Each TCP payload starts with sequence of 
>> bytes which can be used for load balancing and stickiness. Each packet 
>> starts with
>>
>> 4B ... protocol identifier FF00FF00
>> 1B ... protocol version
>> 4B ... ID which can be used for stickiness
>> 4B ... metadata
>>
>> Having this in mind I decided to define a binary stick-table
>> |stick-table type binary len 4 size 50 expire 2m|
>> and stick on derective
>> |stick on req.payload(5,4)|
>>
>> When ID is 0 everything works, i.e., printing the stick table shows me 
>> key=0000 and selected server, and all the communication is sticked to 
>> the one selected server. However, when ID is not 0 I never get 
>> stick-table entry and each TCP session goes to a different worker 
>> according to the roundrobin.
>>
>> I am afraid that it is some kind of a bug because I tried to use 
>> string stick table as well without success. Example of a simple 
>> communication is enclosed
>>
>> Also, I can provide TCP server and client to generate this kind of 
>> communication..
>>
>> Thank you for help, Milos
>>
> 
> 

Hi,

Did you use tcp-inspect delay, without this parameter you do not have the
warranty that data is available in the buffer (see example of
https://cbonte.github.io/haproxy-dconv/configuration-1.5.html#4.2-stick%20store-response).

R,
Emeric



Reply via email to