ovs-xapi-sync: Always set iface-id, not just when xs-vif-uuid changes.
authorBen Pfaff <blp@nicira.com>
Thu, 2 Feb 2012 01:18:52 +0000 (17:18 -0800)
committerBen Pfaff <blp@nicira.com>
Fri, 10 Feb 2012 16:37:22 +0000 (08:37 -0800)
commit4eb7305b61ac9e961ba3307a7f60abc0754d8c31
tree905ee57f7263d6318db360e4fc0795dadd461fcf
parent2b186a31d24cff01fe33893d20d73f80edb73b99
ovs-xapi-sync: Always set iface-id, not just when xs-vif-uuid changes.

When XAPI moves an interface from one bridge to another, the vif script
removes the vif from one bridge and adds it to (possibly) a different
bridge in a single transaction.  The new record does not have an iface-id
initially (because the vif script never adds the iface-id initially) but
it has the same name and xs-vif-uuid as the old one, so the caching logic
in ovs-xapi-sync failed to add a new iface-id.  This commit fixes the
caching logic.

Observed on XenServer 5.6.100.  It's possible that XAPI behavior changed in
later versions so the bug cannot be triggered there, but we have not
checked.

Bug #9414.
Reported-by: Duffie Cooley <dcooley@nicira.com>
Signed-off-by: Ben Pfaff <blp@nicira.com>
xenserver/usr_share_openvswitch_scripts_ovs-xapi-sync