]> review.fuel-infra Code Review - openstack-build/neutron-build.git/commit
DVR:Fix _notify_l3_agent_new_port for proper arp update
authorSwaminathan Vasudevan <swaminathan.vasudevan@hp.com>
Fri, 4 Dec 2015 19:58:57 +0000 (11:58 -0800)
committerSwaminathan Vasudevan <swaminathan.vasudevan@hp.com>
Mon, 21 Dec 2015 21:30:39 +0000 (13:30 -0800)
commitb223452e68fa8629cb67826bb8ae3ac612e0b859
tree1af3a328394ec078298ae984885199e860e46bfd
parentaea286df7766b313d1535164072dab7d232c720f
DVR:Fix _notify_l3_agent_new_port for proper arp update

Now with notifications coming from ml2 plugin on port create
and port update, it is worth fixing the existing _notify_
l3_agent_new_port for proper arp update and router scheduling.

Previously we have been sending arp update and calling router
scheduling for every update notification for service ports,
but now we can take necessary action only when required, since
the fix to update the arp and router scheduling was recently
done by sending the port info for every new port created.

When _notify_l3_agent_port_update is triggered, we check if the
original port host binding exists and if there is a change in
host binding with respect to the new port, then we go ahead and
reschedule the router on the new host and flush the arp entry.

Related-Bug: #1524020

Change-Id: Ifda623d5413b72bf80f38fba5c12a05a88bb7de5
neutron/db/l3_dvrscheduler_db.py
neutron/tests/unit/scheduler/test_l3_agent_scheduler.py