Hostconfig for Openstack in VPP renderer 17/48217/4
authorTomas Cechvala <tcechval@cisco.com>
Thu, 10 Nov 2016 14:38:54 +0000 (15:38 +0100)
committerTomas Cechvala <tcechval@cisco.com>
Tue, 15 Nov 2016 15:48:56 +0000 (15:48 +0000)
commit70762f11bb7afd997bdb525c7d3b9d17481af65b
tree342b1d36c9c676ead0d5f6342b40774d343712b3
parent88d2213d806ecb4712351676e1a4ef471f560ca8
Hostconfig for Openstack in VPP renderer

Different underlay technologies may be used in multinode
environment (ovs, vpp, etc.)

Configuration for hosts on a particular node may be passed to
Openstack by using hostconfigs feature.

If GBP discoveres a VPP capable node, neutron-vpp-mapper
(if installed) will react to this by exposing a config
specific for the node into
/restconf/operational/neutron:neutron/hostconfigs

On the Openstack side, pseudo-agent-binding port binding
controller (networking-odl) will periodically scan the
datatree mentioned above and if it finds data, it will update
agent database (neutron) with them.

Later on, if someone is going to boot nova instance, nova will
bind the port in such a way as the configuration in agent DB for
the given node tells it.

E.g. if vif_type is 'ovs', a port will be created and bound to
OVS. If it's 'vhostuser' nova will bind the port to a vhostuser
socket (which path is also specified in the config)

How to enable hostconfig feature in Devstack/Openstack:
modify ml2.conf by adding the following lines:
port_binding_controller=pseudo-agentdb-binding
ODL_HOSTCONF_URI=restconf/operational/neutron:neutron/hostconfigs
URL=<your_url, e.g http://127.0.0.1:8080/>

Change-Id: I43dd10a4dc0d7bb62ab3c9f0c6b100718b528cad
Signed-off-by: Tomas Cechvala <tcechval@cisco.com>
neutron-vpp-mapper/src/main/java/org/opendaylight/groupbasedpolicy/neutron/vpp/mapper/NeutronVppMapper.java
neutron-vpp-mapper/src/main/java/org/opendaylight/groupbasedpolicy/neutron/vpp/mapper/SocketInfo.java
neutron-vpp-mapper/src/main/java/org/opendaylight/groupbasedpolicy/neutron/vpp/mapper/hostconfigs/VppNodeListener.java [new file with mode: 0644]
neutron-vpp-mapper/src/main/java/org/opendaylight/groupbasedpolicy/neutron/vpp/mapper/util/HostconfigUtil.java [new file with mode: 0644]
neutron-vpp-mapper/src/test/java/org/opendaylight/groupbasedpolicy/neutron/vpp/mapper/hostconfigs/TestResources.java [new file with mode: 0644]
neutron-vpp-mapper/src/test/java/org/opendaylight/groupbasedpolicy/neutron/vpp/mapper/hostconfigs/VppNodeListenerTest.java [new file with mode: 0644]
neutron-vpp-mapper/src/test/java/org/opendaylight/groupbasedpolicy/neutron/vpp/mapper/util/HostconfigUtilTest.java [new file with mode: 0644]