diff options
| author | Michael Larson <mike@vyatta.com> | 2011-09-12 14:58:32 -0700 |
|---|---|---|
| committer | Michael Larson <mike@vyatta.com> | 2011-09-12 14:58:32 -0700 |
| commit | 1ac321d8093787035c09c0bcabaae64bef7f5d2e (patch) | |
| tree | 84b62b4bfdc02e77b4aec35f341daa782b9ce3de /src/lbdata.cc | |
| parent | 9ea51f6fd9e901f472aa445d8f8597d93b94153b (diff) | |
| download | vyatta-wanloadbalance-1ac321d8093787035c09c0bcabaae64bef7f5d2e.tar.gz vyatta-wanloadbalance-1ac321d8093787035c09c0bcabaae64bef7f5d2e.zip | |
fix for bug 7315. Target status behavior has been modified to fix this bug:
vyatta@vyatta# run show wan-load-balance
Interface: eth0
Status: active
Last Status Change: Mon Sep 12 21:55:13 2011
-Test: ping Target: 8.8.8.8
+Test: ping Target: 10.3.0.120
Test: ping Target: 127.0.0.1
Last Interface Success: 0s
Last Interface Failure: n/a
# Interface Failure(s): 0
[edit]
vyatta@vyatta# run show wan-load-balance
Interface: eth0
Status: active
Last Status Change: Mon Sep 12 21:55:13 2011
+Test: ping Target: 8.8.8.8
Test: ping Target: 10.3.0.120
Test: ping Target: 127.0.0.1
Last Interface Success: 0s
Last Interface Failure: n/a
# Interface Failure(s): 0
- denotes failed test
+ denotes successful test
blank means the test wasn't performed
All test status' refer to the last test cycle.
Diffstat (limited to 'src/lbdata.cc')
| -rw-r--r-- | src/lbdata.cc | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/lbdata.cc b/src/lbdata.cc index 39deaa6..99c36e7 100644 --- a/src/lbdata.cc +++ b/src/lbdata.cc @@ -66,6 +66,12 @@ LBHealth::put(int rtt) void LBHealth::start_new_test_cycle() { + //let's first clear out all the old results + TestIter t = _test_coll.begin(); + while (t != _test_coll.end()) { + t->second->_state = LBTest::K_NONE; + ++t; + } _test_iter = _test_coll.begin(); // _test_iter->second->start(); } |
