diff options
author | YAMADA Hideki <yamada.hideki@po.ntts.co.jp> | 2013-03-28 18:50:28 +0900 |
---|---|---|
committer | FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp> | 2013-03-31 18:13:26 +0900 |
commit | 51baabb9ee9cffc7c49bc22dc202bc55feadb4e7 (patch) | |
tree | cc2a52ad8087b8e9809feef248e031782210a24e /bin | |
parent | fd7a4e61197cbc6657b64f3658178081b059a762 (diff) |
ryu-client: support Topology REST API
Signed-off-by: YAMADA Hideki <yamada.hideki@po.ntts.co.jp>
Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
Diffstat (limited to 'bin')
-rwxr-xr-x | bin/ryu-client | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/bin/ryu-client b/bin/ryu-client index 292ee261..ea3a3eaa 100755 --- a/bin/ryu-client +++ b/bin/ryu-client @@ -23,6 +23,7 @@ from ryu.app.client import OFPClient from ryu.app.client import QuantumIfaceClient from ryu.app.client import SwitchConfClient from ryu.app.client import TunnelClient +from ryu.app.client import TopologyClient def client_test(): @@ -41,6 +42,7 @@ def client_test(): tun_client = TunnelClient(address) sc_client = SwitchConfClient(address) qi_client = QuantumIfaceClient(address) + topo_client = TopologyClient(address) commands = { 'list_nets': lambda a: sys.stdout.write(ofp_client.get_networks()), @@ -87,6 +89,9 @@ def client_test(): qi_client.get_network_id(a[1])), 'qi_create_net_id': lambda a: qi_client.create_network_id(a[1], a[2]), 'qi_update_net_id': lambda a: qi_client.update_network_id(a[1], a[2]), + + 'topo_list_switches': lambda a: topo_client.list_switches(), + 'topo_list_links': lambda a: topo_client.list_links(), } # allow '-', instead of '_' |