Moved ARP on top of network map device storage. This required improvements to the device storage, most notably to improved IP address handling by representing IP addresses as separate vertices rather than a serialized string in the Device vertex
diff --git a/src/main/java/net/onrc/onos/ofcontroller/core/internal/SwitchStorageImpl.java b/src/main/java/net/onrc/onos/ofcontroller/core/internal/SwitchStorageImpl.java
index 26d4e40..8d93acf 100644
--- a/src/main/java/net/onrc/onos/ofcontroller/core/internal/SwitchStorageImpl.java
+++ b/src/main/java/net/onrc/onos/ofcontroller/core/internal/SwitchStorageImpl.java
@@ -333,6 +333,11 @@
}
}
+ // TODO There's an issue here where a port with that ID could already
+ // exist when we try to add this one (because it's left over from an
+ // old topology). We need to remove an old port with the same ID when
+ // we add the new port. Also it seems that old ports like this are
+ // never cleaned up and will remain in the DB in the ACTIVE state forever.
private IPortObject addPortImpl(ISwitchObject sw, short portNum) {
IPortObject p = op.newPort(sw.getDPID(), portNum);
p.setState("ACTIVE");