Skip to content

Commit

Permalink
Only complain on RIB injection if no peer can take it #1179
Browse files Browse the repository at this point in the history
The behaviour was to return an issue if any of the peers could
not take the RIB. With the new `neighbor *` feature bulk sending
routes should now be accepted.

If any peer can accept the route as the family was negotiated,
then the announcement was a success, only a failure if no peers
could take it.
  • Loading branch information
thomas-mangin committed Oct 31, 2023
1 parent 224f240 commit 48270f8
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/exabgp/configuration/configuration.py
Original file line number Diff line number Diff line change
Expand Up @@ -60,16 +60,16 @@ def __init__(self):
self.neighbors = {}

def inject_change(self, peers, change):
result = True
result = False
for neighbor_name in self.neighbors:
if neighbor_name in peers:
neighbor = self.neighbors[neighbor_name]
if change.nlri.family() in neighbor.families():
# remove_self may well have side effects on change
neighbor.rib.outgoing.add_to_rib(neighbor.remove_self(change))
result = True
else:
log.error('the route family is not configured on neighbor', 'configuration')
result = False
return result

def inject_eor(self, peers, family):
Expand Down

0 comments on commit 48270f8

Please sign in to comment.