Simplify anti-entropy code
Change-Id: I6568b1cc7c67e12c5a81ec9f8680f6461813ddce
diff --git a/core/store/dist/src/main/java/org/onosproject/store/device/impl/GossipDeviceStore.java b/core/store/dist/src/main/java/org/onosproject/store/device/impl/GossipDeviceStore.java
index f16bd06..f8e19c0 100644
--- a/core/store/dist/src/main/java/org/onosproject/store/device/impl/GossipDeviceStore.java
+++ b/core/store/dist/src/main/java/org/onosproject/store/device/impl/GossipDeviceStore.java
@@ -1170,7 +1170,8 @@
Timestamped<DeviceDescription> lProvDevice = lDeviceDescs.getDeviceDesc();
Timestamp advDevTimestamp = devAds.get(devFragId);
- if (advDevTimestamp == null || lProvDevice.isNewer(advDevTimestamp)) {
+ if (advDevTimestamp == null || lProvDevice.isNewerThan(
+ advDevTimestamp)) {
// remote does not have it or outdated, suggest
notifyPeer(sender, new InternalDeviceEvent(provId, deviceId, lProvDevice));
} else if (!lProvDevice.timestamp().equals(advDevTimestamp)) {
@@ -1188,7 +1189,8 @@
final PortFragmentId portFragId = new PortFragmentId(deviceId, provId, num);
Timestamp advPortTimestamp = portAds.get(portFragId);
- if (advPortTimestamp == null || lPort.isNewer(advPortTimestamp)) {
+ if (advPortTimestamp == null || lPort.isNewerThan(
+ advPortTimestamp)) {
// remote does not have it or outdated, suggest
notifyPeer(sender, new InternalPortStatusEvent(provId, deviceId, lPort));
} else if (!lPort.timestamp().equals(advPortTimestamp)) {