From 45050d9b97f3821c6dbdbc98678a62ddfcf81aad Mon Sep 17 00:00:00 2001 From: FUJITA Tomonori Date: Mon, 25 Apr 2016 23:52:21 +0900 Subject: remove collector mode support We need to update yang config collector mode (split into config and state). before that, let's remove the feature itself to see if there is any user of it. Signed-off-by: FUJITA Tomonori --- table/adj.go | 19 +++++++------------ 1 file changed, 7 insertions(+), 12 deletions(-) (limited to 'table/adj.go') diff --git a/table/adj.go b/table/adj.go index a58f87aa..8d298be4 100644 --- a/table/adj.go +++ b/table/adj.go @@ -21,22 +21,20 @@ import ( ) type AdjRib struct { - id string - accepted map[bgp.RouteFamily]int - table map[bgp.RouteFamily]map[string]*Path - isCollector bool + id string + accepted map[bgp.RouteFamily]int + table map[bgp.RouteFamily]map[string]*Path } -func NewAdjRib(id string, rfList []bgp.RouteFamily, isCollector bool) *AdjRib { +func NewAdjRib(id string, rfList []bgp.RouteFamily) *AdjRib { table := make(map[bgp.RouteFamily]map[string]*Path) for _, rf := range rfList { table[rf] = make(map[string]*Path) } return &AdjRib{ - id: id, - table: table, - accepted: make(map[bgp.RouteFamily]int), - isCollector: isCollector, + id: id, + table: table, + accepted: make(map[bgp.RouteFamily]int), } } @@ -47,9 +45,6 @@ func (adj *AdjRib) Update(pathList []*Path) { } rf := path.GetRouteFamily() key := path.getPrefix() - if adj.isCollector { - key += path.GetSource().Address.String() - } old, found := adj.table[rf][key] if path.IsWithdraw { -- cgit v1.2.3