-
Notifications
You must be signed in to change notification settings - Fork 4.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
allow roundrobin algorithm as a choice in passthrough/reencrypt #9710
Conversation
[test] |
LGTM maybe add |
@@ -252,7 +252,13 @@ backend be_tcp_{{$cfgIdx}} | |||
{{ if ne (env "ROUTER_SYSLOG_ADDRESS" "") ""}} | |||
option tcplog | |||
{{ end }} | |||
{{ with $balanceAlgo := index $cfg.Annotations "router.openshift.io/haproxy.balance" }} | |||
{{ with $matchValue := (matchValues $balanceAlgo "roundrobin" "leastconn" ) }} | |||
balance {{ $balanceAlgo }} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm just template ignorant. What value does https://github.com/openshift/origin/pull/9710/files#diff-dc1a3cefa4a5177a9bfd475c81220cf1R256 bring? Does it cause the entire template processing to fail if the match fails?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No, the template processing does not fail. It just means that the 'with' block will not be processed further. Treat that as an 'if' statement.
[test] again |
Evaluated for origin test up to c94ec71 |
continuous-integration/openshift-jenkins/test SUCCESS (https://ci.openshift.redhat.com/jenkins/job/test_pr_origin/5859/) |
@eparis / @openshift/networking |
[merge] |
continuous-integration/openshift-jenkins/merge SUCCESS (https://ci.openshift.redhat.com/jenkins/job/test_pr_origin/5866/) (Image: devenv-rhel7_4540) |
Evaluated for origin merge up to c94ec71 |
For the passthrough and reencrypt routes, the choice of balancing algorithm was not provided through annotations. Making that possible with this PR. Weights depend on the fact that the balancing algorithm be 'roundrobin'.