Fix balance algorithm to maintain affinity between a server

and a client.
This commit is contained in:
Takashi Sogabe
2014-09-09 14:43:09 +09:00
parent af15a9ae0a
commit 8d6cd607c8

View File

@@ -28,7 +28,7 @@ listen stats :8888
{% if units %}
{% for service, ports in service_ports.iteritems() -%}
listen {{ service }} 0.0.0.0:{{ ports[0] }}
balance roundrobin
balance source
option tcplog
{% for unit, address in units.iteritems() -%}
server {{ unit }} {{ address }}:{{ ports[1] }} check