Check for the SHARD Status before opening the OVSDB port/HwvtepSouthboundProvider... 29/83229/5
authorChandra Shekar S <chandra.shekar.s@ericsson.com>
Wed, 24 Jul 2019 09:49:01 +0000 (15:19 +0530)
committerChandra Shekar S <chandra.shekar.s@ericsson.com>
Wed, 8 Jan 2020 10:57:51 +0000 (16:27 +0530)
commitbe1d1857fcd2337fee1cbae751d91306791c7442
tree8e09fdae600a77e4d0916adb7996ffc3e72e1ab2
parentca01e9f43aff77d5e4cdd84d29e1190e8a898f42
Check for the SHARD Status before opening the OVSDB port/HwvtepSouthboundProvider intialization.

JIRA: OVSDB-484

Currently the HwvtepSouthboundProvider is intialized and the Ovsdb port is opened.
As soon as the Ovsdb port is opened the tors will connected to the HwvtepSouthboundPlugin.
The HwvtepSouthboundPlugin will process the connected tors and tries to build the topology operational
and further the topology config and tries to update these datastores.
If the topology SHARDs are not up or the SHARD leaders are not elected by this time, it ends up in the
exceptions while updating the datastores and the operational and config datastores will not be populated
with the expected data.

The fix is check for the topology config and operational SHARDs status up and Leaders for these are
elected and then initialize HwvtepSouthboundProvider and start Ovsdb port when they are up.

Signed-off-by: Chandra Shekar S <chandra.shekar.s@ericsson.com>
Change-Id: Ia8599b9ed9cc3d5afbdb29a951cebee01c15ddbe
hwvtepsouthbound/hwvtepsouthbound-impl/pom.xml
hwvtepsouthbound/hwvtepsouthbound-impl/src/main/java/org/opendaylight/ovsdb/hwvtepsouthbound/HwvtepSouthboundProvider.java
hwvtepsouthbound/hwvtepsouthbound-impl/src/main/java/org/opendaylight/ovsdb/hwvtepsouthbound/HwvtepSouthboundProviderConfigurator.java [new file with mode: 0644]
hwvtepsouthbound/hwvtepsouthbound-impl/src/main/resources/OSGI-INF/blueprint/hwvtepsouthbound.xml
hwvtepsouthbound/hwvtepsouthbound-impl/src/main/resources/initial/hwvtepsouthbound.cfg [new file with mode: 0644]
utils/mdsal-utils/src/main/java/org/opendaylight/ovsdb/utils/mdsal/utils/ShardStatusMonitor.java [new file with mode: 0644]