Mercurial > hg > nginx
comparison src/http/ngx_http_upstream_round_robin.c @ 1425:debd1ba60d3f
cancel dynamic weights,
it seems that may permanently set lower weight or even mark server as down
author | Igor Sysoev <igor@sysoev.ru> |
---|---|
date | Mon, 27 Aug 2007 16:02:43 +0000 |
parents | 79f033a89dd4 |
children | f8142ab2bace |
comparison
equal
deleted
inserted
replaced
1424:937fbbf611cd | 1425:debd1ba60d3f |
---|---|
513 return n; | 513 return n; |
514 } | 514 } |
515 | 515 |
516 for (i = 0; i < peers->number; i++) { | 516 for (i = 0; i < peers->number; i++) { |
517 if (peer[i].fails == 0) { | 517 if (peer[i].fails == 0) { |
518 peer[i].current_weight += peer[i].weight; | 518 peer[i].current_weight = peer[i].weight; |
519 | 519 |
520 } else { | 520 } else { |
521 /* 1 allows to go to quick recovery when all peers failed */ | 521 /* 1 allows to go to quick recovery when all peers failed */ |
522 peer[i].current_weight = 1; | 522 peer[i].current_weight = 1; |
523 } | 523 } |