napalm
napalm copied to clipboard
get routes neighbour
add a getter Instead of the previous pull request of get_received_routes change to get_routes_neighbour, the method will receive the following args: protocol (BGP, or any other supported protocol) direction (in/out) neighbour
The getter will return: list of learned routes as dict (can add more info later, like LP, AS-path, etc')
The name itself seems awkward. Instead of get_routes_neighbor, maybe it would be better to use get_adj_rib_in and get_adj_rib_out or something similar?
maybe get_adj_rib?
I want to have the direction in the method
We are generally trying to avoid adding new getters and instead think we should probably focus on napalm-yang for new getters. That being said, I am open to discussions on enabling this (somehow in the napalm community repositories). If there is a way this could reasonable be accomplished.
Hi @ktbyers Wish I understood the Napalm-Yang couldn't get my head around it.
Anyway my latest though was to get the feature into get_routes and maybe add two args for neighbour and neighbour_direction instead of adding a new getter
That would be an API change, @omershtivi - which I wouldn't disagree with. Would you be happy to address these in a PR?
I have a working implementation on junos. Just needs a bit of cleanup and then I'll submit a PR