diff options
author | FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp> | 2015-01-18 16:04:13 +0900 |
---|---|---|
committer | FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp> | 2015-01-18 16:04:13 +0900 |
commit | ec278710f10c2cae7d6b3e393aa957edfd536181 (patch) | |
tree | cb8e6ec6c38ceab014d98d3ab95f159bc9d10411 /config/default.go | |
parent | a9e55d3bd75fd5dd633fee1ff2c9d45d6d6447ee (diff) |
server: support idlehold time after reset
After resetting a peer, the peer will remain idle for idlehold time
(by default 30 seconds). It can be configured via
IdleHoldTImeAfterReset.
Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
Diffstat (limited to 'config/default.go')
-rw-r--r-- | config/default.go | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/config/default.go b/config/default.go index 1b9b59c5..f4a2e301 100644 --- a/config/default.go +++ b/config/default.go @@ -1,7 +1,8 @@ package config const ( - DEFAULT_HOLDTIME = 90 + DEFAULT_HOLDTIME = 90 + DEFAULT_IDLE_HOLDTIME_AFTER_RESET = 30 ) func setTimersTypeDefault(timersT *TimersType) { @@ -11,6 +12,9 @@ func setTimersTypeDefault(timersT *TimersType) { if timersT.KeepaliveInterval == 0 { timersT.KeepaliveInterval = timersT.HoldTime / 3 } + if timersT.IdleHoldTImeAfterReset == 0 { + timersT.IdleHoldTImeAfterReset = float64(DEFAULT_IDLE_HOLDTIME_AFTER_RESET) + } } func SetNeighborTypeDefault(neighborT *NeighborType) { |