bgp: add 'neighbors.get' and 'show.rib' JSON RPC API
Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
This commit is contained in:
parent
45ac298d01
commit
86a975aca6
@ -71,6 +71,16 @@ class BgpWSJsonRpc(app_manager.RyuApp):
|
||||
call('network.add', **networks)
|
||||
return {}
|
||||
|
||||
@rpc_public('neighbors.get')
|
||||
def _neighbors_get(self):
|
||||
return call('neighbors.get')
|
||||
|
||||
@rpc_public('show.rib')
|
||||
def _show_rib(self, family='ipv4'):
|
||||
show = {}
|
||||
show['params'] = ['rib', family]
|
||||
return call('operator.show', **show)
|
||||
|
||||
|
||||
class BgpWSJsonRpcController(ControllerBase):
|
||||
def __init__(self, req, link, data, **config):
|
||||
|
Loading…
x
Reference in New Issue
Block a user