Switch from using a Long for FlowId to an Uri 59/4059/3
authorEd Warnicke <eaw@cisco.com>
Tue, 7 Jan 2014 21:50:53 +0000 (13:50 -0800)
committerEd Warnicke <eaw@cisco.com>
Mon, 13 Jan 2014 00:39:54 +0000 (18:39 -0600)
This patch will build only after http://git.opendaylight.org/gerrit/4058 is merged

Change-Id: Ia2348c24bf53d91c11922badcd288575e0175aac
Signed-off-by: Moiz Raja <moraja@cisco.com>
Signed-off-by: Ed Warnicke <eaw@cisco.com>
drop-test/src/main/java/org/opendaylight/openflowplugin/droptest/DropTestCommiter.xtend
drop-test/src/main/java/org/opendaylight/openflowplugin/outputtest/OutputTestUtil.xtend
test-provider/src/main/java/org/opendaylight/openflowplugin/test/OpenflowpluginTestCommandProvider.java

index 5c36218ebb79fe34f6187345f5fe6d1ebca287e3..85fc5463a40cf08508e8f590083082baaa4b5107 100644 (file)
@@ -89,7 +89,7 @@ class DropTestCommiter implements PacketProcessingListener {
         val fb = new FlowBuilder();
         fb.setMatch(match.build());
         fb.setInstructions(isb.build());
-        fb.setId(new FlowId(new Long(fb.hashCode)));
+        fb.setId(new FlowId(Long.toString(fb.hashCode)));
         fb.setPriority(4);
         fb.setBufferId(0L);
         val value = new BigInteger("10", 10);
index 7dbcde8006e650363548350ed132332bea7564e3..82df9a1678c37c8d33fb8bc01d2764900c41d538 100644 (file)
@@ -132,7 +132,7 @@ class OutputTestUtil {
         fBuild.setMatch(new MatchBuilder().build)
         fBuild.setInstructions(createPingInstructionsBuilder().build)
         
-        var key = new FlowKey(new FlowId(flowId));
+        var key = new FlowKey(new FlowId(Long.toString(flowId)));
         fBuild.setBarrier(false);
         // flow.setBufferId(new Long(12));
         var value = new BigInteger("10", 10);
@@ -144,7 +144,7 @@ class OutputTestUtil {
         fBuild.setStrict(false);
         fBuild.setContainerName(null);
         fBuild.setFlags(new FlowModFlags(false, false, false, false, false));
-        fBuild.setId(new FlowId(new Long(12)));
+        fBuild.setId(new FlowId("12"));
         fBuild.setTableId(checkTableId(tableId));
         fBuild.setOutGroup(new Long(2));
         fBuild.setOutPort(value);
index aea2830318062f5aa27a1c9809ef3f36e59a3ad3..3e8552ea3e630928c234dc075b8c426840732b43 100644 (file)
@@ -742,7 +742,7 @@ public class OpenflowpluginTestCommandProvider implements CommandProvider {
             LOG.warn("flow type not understood: {}", flowType);
         }
 
-        FlowKey key = new FlowKey(new FlowId(id));
+        FlowKey key = new FlowKey(new FlowId(Long.toString(id)));
         if (null == flow.isBarrier()) {
             flow.setBarrier(Boolean.FALSE);
         }
@@ -757,7 +757,7 @@ public class OpenflowpluginTestCommandProvider implements CommandProvider {
         flow.setStrict(false);
         flow.setContainerName(null);
         flow.setFlags(new FlowModFlags(false, false, false, false, true));
-        flow.setId(new FlowId(new Long(12)));
+        flow.setId(new FlowId("12"));
         flow.setTableId(getTableId(tableId));
         flow.setOutGroup(new Long(2));
         // set outport to OFPP_NONE (65535) to disable remove restriction for