Fix latency constraint
1. Consider that the type "Duration" in the String is composed by
characters and numbers, it's not easy to convert it to double for
comparison, I modified the latency's annotation to
cfg.latency().toNanos().
2. Exclude two EdgeLinks for the calculation of the whole path's latency
3. The unit of latency in ONOS is not the same, so I set all the latency units to
nanoseconds.
4. Add the latency constraint option for ConnectivityIntentCommand.
Change-Id: Iddf5634880e43ed563db9978659db5eb9ee6c7f8
diff --git a/core/api/src/main/java/org/onosproject/net/AnnotationKeys.java b/core/api/src/main/java/org/onosproject/net/AnnotationKeys.java
index 4101738..665565d 100644
--- a/core/api/src/main/java/org/onosproject/net/AnnotationKeys.java
+++ b/core/api/src/main/java/org/onosproject/net/AnnotationKeys.java
@@ -101,7 +101,7 @@
/**
* Annotation key for latency.
- * The value of this key is expected to be latency in microsecond.
+ * The value of this key is expected to be latency in nanosecond.
*/
public static final String LATENCY = "latency";