bgp: fix non configured peer exception

peer is None if the connection comes from non configured bgp peer.

Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
bgp: set bgp-config-file default None

allowing not use a config file.

Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
bgp: add JSON RPC API

Adds JSON RPC API on web socket to dynamically configure bgp. This is
the initial support (there are still tons of APIs that are not
exported via JSON RPC API).

$ sudo PYTHONPATH=.:$PYTHONPATH ryu-manager ryu/services/protocols/bgp/api/jsonrpc.py ryu/services/protocols/bgp/application.py

then you can configure on another terminal:

~ fujita$ wsdump.py ws://127.0.0.1:8080/bgp/ws
Press Ctrl+C to quit
> {"jsonrpc": "2.0", "id": 1, "method": "core.start", "params" : {"as_number":64512, "router_id":"10.0.0.2"}}
< {"jsonrpc": "2.0", "id": 1, "result": {}}
> {"jsonrpc": "2.0", "id": 1, "method": "neighbor.create", "params" : {"ip_address":"192.168.177.32", "remote_as":64513}}
< {"jsonrpc": "2.0", "id": 1, "result": {}}
> {"jsonrpc": "2.0", "id": 1, "method": "network.add", "params" : {"prefix":"10.20.0.0/24"}}
< {"jsonrpc": "2.0", "id": 1, "result": {}}

Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
bgp: add 'neighbors.get' and 'show.rib' JSON RPC API

Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
sw test tool: Add a default test file (group:indirect)

This test file aims to examine 'group action' of FlowMod message.

Signed-off-by: Yuichi Ito <ito.yuichi0@gmail.com>