diff options
| author | slioch <slioch@eng-140.vyatta.com> | 2009-07-24 16:59:27 -0700 |
|---|---|---|
| committer | slioch <slioch@eng-140.vyatta.com> | 2009-07-24 16:59:27 -0700 |
| commit | f672a6d5ca04b643a9d8583fcb8ade4da9fde6f3 (patch) | |
| tree | 07bf2b8289e4bffc561f5d0fc7bb1c664d7ee6da /src/lbdata.cc | |
| parent | e99605daeed8b412073694ee35d54da78920703f (diff) | |
| download | vyatta-wanloadbalance-f672a6d5ca04b643a9d8583fcb8ade4da9fde6f3.tar.gz vyatta-wanloadbalance-f672a6d5ca04b643a9d8583fcb8ade4da9fde6f3.zip | |
bug fixes on mult targets. added packet rate limit option to rules
Diffstat (limited to 'src/lbdata.cc')
| -rw-r--r-- | src/lbdata.cc | 24 |
1 files changed, 21 insertions, 3 deletions
diff --git a/src/lbdata.cc b/src/lbdata.cc index 9c33f51..4dc8d76 100644 --- a/src/lbdata.cc +++ b/src/lbdata.cc @@ -69,9 +69,6 @@ void LBHealth::start_new_test_cycle() { _test_iter = _test_coll.begin(); - if (_test_iter != _test_coll.end()) { - _test_iter->second->init(); - } _test_success = false; } @@ -85,6 +82,7 @@ LBHealth::send_test() if (_test_success == true || _test_iter == _test_coll.end()) { return; //means we are done } + _test_iter->second->init(); _test_iter->second->send(*this); } @@ -226,6 +224,26 @@ LBData::dump() cout << " " << r_iter->second._d_addr << endl; cout << " " << r_iter->second._d_port << endl; + if (r_iter->second._limit) { + cout << " limit:" << endl; + cout << " burst: " << r_iter->second._limit_burst << endl; + cout << " rate: " << r_iter->second._limit_burst << endl; + if (r_iter->second._limit_mode) { + cout << " thresh: above" << endl; + } + else { + cout << " thresh: below" << endl; + } + if (r_iter->second._limit_period == LBRule::K_SECOND) { + cout << " period: second" << endl; + } + else if (r_iter->second._limit_period == LBRule::K_MINUTE) { + cout << " period: minute" << endl; + } + else if (r_iter->second._limit_period == LBRule::K_HOUR) { + cout << " period: hour" << endl; + } + } LBRule::InterfaceDistIter ri_iter = r_iter->second._iface_dist_coll.begin(); while (ri_iter != r_iter->second._iface_dist_coll.end()) { cout << " interface: " << ri_iter->first << endl; |
