Minor improvements
- Fix typo
- Remove unnecessary warnings
- Ignore dhcp config register/unregister event
- Ignore interface IP update when there is no host discovered on that interface
Change-Id: I530fe36eb063ac8b3397c86e888c0a6c2ab8984b
diff --git a/apps/dhcprelay/src/main/java/org/onosproject/dhcprelay/DhcpRelayManager.java b/apps/dhcprelay/src/main/java/org/onosproject/dhcprelay/DhcpRelayManager.java
index 39123ac..cd4e3b5 100644
--- a/apps/dhcprelay/src/main/java/org/onosproject/dhcprelay/DhcpRelayManager.java
+++ b/apps/dhcprelay/src/main/java/org/onosproject/dhcprelay/DhcpRelayManager.java
@@ -596,6 +596,9 @@
log.info("{} removed", config.getClass().getSimpleName());
});
break;
+ case CONFIG_REGISTERED:
+ case CONFIG_UNREGISTERED:
+ break;
default:
log.warn("Unsupported event type {}", event.type());
break;
diff --git a/apps/segmentrouting/app/src/main/java/org/onosproject/segmentrouting/HostHandler.java b/apps/segmentrouting/app/src/main/java/org/onosproject/segmentrouting/HostHandler.java
index e4efabb..5fdbf69 100644
--- a/apps/segmentrouting/app/src/main/java/org/onosproject/segmentrouting/HostHandler.java
+++ b/apps/segmentrouting/app/src/main/java/org/onosproject/segmentrouting/HostHandler.java
@@ -440,6 +440,7 @@
Set<Host> hosts = hostService.getConnectedHosts(connectPoint);
if (hosts == null || hosts.size() == 0) {
+ log.debug("processIntfVlanUpdatedEvent: No hosts connected to {}", connectPoint);
return;
}
@@ -472,7 +473,7 @@
Set<Host> hosts = hostService.getConnectedHosts(cp);
if (hosts == null || hosts.size() == 0) {
- log.warn("processIntfIpUpdatedEvent: No hosts connected to {}", cp);
+ log.debug("processIntfIpUpdatedEvent: No hosts connected to {}", cp);
return;
}
diff --git a/apps/segmentrouting/app/src/main/java/org/onosproject/segmentrouting/SegmentRoutingManager.java b/apps/segmentrouting/app/src/main/java/org/onosproject/segmentrouting/SegmentRoutingManager.java
index 14989d1..eebce8c 100644
--- a/apps/segmentrouting/app/src/main/java/org/onosproject/segmentrouting/SegmentRoutingManager.java
+++ b/apps/segmentrouting/app/src/main/java/org/onosproject/segmentrouting/SegmentRoutingManager.java
@@ -253,7 +253,7 @@
private final InternalMastershipListener mastershipListener = new InternalMastershipListener();
//Completable future for network configuration process to buffer config events handling during activation
private CompletableFuture<Boolean> networkConfigCompletion = null;
- private List<Event> quequedEvents = new CopyOnWriteArrayList<>();
+ private List<Event> queuedEvents = new CopyOnWriteArrayList<>();
// Handles device, link, topology and network config events
private ScheduledExecutorService mainEventExecutor;
@@ -454,7 +454,7 @@
//setting to null for easier fall through
networkConfigCompletion = null;
//process all queued events
- quequedEvents.forEach(event -> {
+ queuedEvents.forEach(event -> {
mainEventExecutor.execute(new InternalEventHandler(event));
});
});
@@ -1437,7 +1437,7 @@
if (networkConfigCompletion == null || networkConfigCompletion.isDone()) {
mainEventExecutor.execute(new InternalEventHandler(event));
} else {
- quequedEvents.add(event);
+ queuedEvents.add(event);
}
break;
default:
@@ -1487,7 +1487,7 @@
if (networkConfigCompletion == null || networkConfigCompletion.isDone()) {
mainEventExecutor.execute(new InternalEventHandler(event));
} else {
- quequedEvents.add(event);
+ queuedEvents.add(event);
}
}
}
@@ -1506,7 +1506,7 @@
if (networkConfigCompletion == null || networkConfigCompletion.isDone()) {
mainEventExecutor.execute(new InternalEventHandler(event));
} else {
- quequedEvents.add(event);
+ queuedEvents.add(event);
}
break;
default:
@@ -1523,7 +1523,7 @@
if (networkConfigCompletion == null || networkConfigCompletion.isDone()) {
mainEventExecutor.execute(new InternalEventHandler(event));
} else {
- quequedEvents.add(event);
+ queuedEvents.add(event);
}
break;
default: