- On node disconnect from Master, notify the respective protocol plugin, not all of them
Change-Id: I2bfb30d2f649a1bc3f07be60150a814bcd1b8a45
Signed-off-by: Alessandro Boch <aboch@cisco.com>
*/
@Override
public void notifyNodeDisconnectFromMaster(Node node) {
- for (String pluginType : this.pluginService.keySet()) {
- IPluginInConnectionService s = pluginService.get(pluginType);
- s.notifyNodeDisconnectFromMaster(node);
+ IPluginInConnectionService s = pluginService.get(node.getType());
+ if (s != null) {
+ s.notifyNodeDisconnectFromMaster(node);
}
}
-}
\ No newline at end of file
+}