1
0
Fork 0

Add support for maximum connections for backends.

This commit is contained in:
kevin 2016-04-13 01:11:36 -07:00
parent 5c8d9f4eb9
commit a15578a8f6
6 changed files with 101 additions and 4 deletions

View file

@ -17,6 +17,16 @@
method = "{{$loadBalancer}}"
{{end}}
{{$maxConnAmt := Get "" . "/maxconn/" "amount"}}
{{$maxConnExtractorFunc := Get "" . "/maxconn/" "extractorfunc"}}
{{with $maxConnAmt}}
{{with $maxConnExtractorFunc}}
[backends.{{Last $backend}}.maxConn]
amount = {{$maxConnAmt}}
extractorFunc = "{{$maxConnExtractorFunc}}"
{{end}}
{{end}}
{{range $servers}}
[backends.{{Last $backend}}.servers.{{Last .}}]
url = "{{Get "" . "/url"}}"