HIGUCHI Yuta
Committed by Gerrit Code Review

ONOS-3841 Only listen to Config change event

Change-Id: I1e9965240ce210240328c0fdb78f8ea529a341a7
...@@ -69,7 +69,17 @@ final class ResourceNetworkConfigListener implements NetworkConfigListener { ...@@ -69,7 +69,17 @@ final class ResourceNetworkConfigListener implements NetworkConfigListener {
69 69
70 @Override 70 @Override
71 public boolean isRelevant(NetworkConfigEvent event) { 71 public boolean isRelevant(NetworkConfigEvent event) {
72 - return CONFIG_CLASSES.contains(event.configClass()); 72 + switch (event.type()) {
73 + case CONFIG_ADDED:
74 + case CONFIG_REMOVED:
75 + case CONFIG_UPDATED:
76 + return CONFIG_CLASSES.contains(event.configClass());
77 +
78 + case CONFIG_REGISTERED:
79 + case CONFIG_UNREGISTERED:
80 + default:
81 + return false;
82 + }
73 } 83 }
74 84
75 @Override 85 @Override
......