Damans227 commented on PR #88:
URL:
https://github.com/apache/cloudstack-kubernetes-provider/pull/88#issuecomment-6025761100
tested this on a kvm lab with a 1.24 cluster running this PR's provider
(83b07d4f). both methods work end to end.
LbCookie on port 80, SourceBased on port 8090. `cmk list
lbstickinesspolicies` for the two rules:
```
"methodname": "LbCookie", "params": {"cookie-name": "SERVERID",
"nocache": "true"}
"methodname": "SourceBased", "params": {"expire": "30m", "tablesize": "200k"}
```
router haproxy config:
```
listen 10_0_60_84-80
server 10_0_60_84-80_0 10.1.1.55:31150 check cookie 10_1_1_55-31150
server 10_0_60_84-80_1 10.1.1.153:31150 check cookie 10_1_1_153-31150
cookie SERVERID insert nocache
listen 10_0_60_85-8090
stick-table type ip size 200k expire 30m
stick on src
```
10 requests each, two app copies on separate nodes:
```
--- LbCookie, no cookie kept:
5 Hostname: whoami-589b5665ff-98l7m
5 Hostname: whoami-589b5665ff-llrqn
--- LbCookie, cookie kept:
10 Hostname: whoami-589b5665ff-llrqn
--- SourceBased, same client:
10 Hostname: whoami-589b5665ff-llrqn
```
setting `cookie-name=APPID` replaced the policy (`set-cookie:
APPID=10_1_1_55-31150`). removing the annotation removed the policy and
requests split again.
bad input fails and cloudstack is left as is:
```
stickiness method LbCookie only works on plain HTTP ports: set appProtocol:
http on them
stickiness method "Bogus" in annotation
service.beta.kubernetes.io/cloudstack-load-balancer-stickiness-method-name is
not supported on this network
```
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]