Complete the work toward Issue #215 and Issue #216:
* Added back-end support for matching conditions and actions for flows.
* Fixed a bug in setting the inPort matching condition.
NOTE: to match IP Source or Destination address, we must
add "matchEthernetFrameType 2048" to the set of matching conditions. E.g:
web/add_flow.py 1 FOOBAR 00:00:00:00:00:00:00:01 0 00:00:00:00:00:00:00:02 0 matchDstMac 00:11:22:33:44:55 matchDstIPv4Net 10.0.0.0/8 matchEthernetFrameType 2048
diff --git a/web/get_flow.py b/web/get_flow.py
index 99e4f3a..eaf50d3 100755
--- a/web/get_flow.py
+++ b/web/get_flow.py
@@ -44,14 +44,12 @@
print "FlowPath: (flowId = %s installerId = %s src = %s/%s dst = %s/%s)" % (flowId, installerId, srcSwitch, srcPort, dstSwitch, dstPort)
for f in parsedResult['dataPath']['flowEntries']:
- inPort = f['inPort']['value']
- outPort = f['outPort']['value']
dpid = f['dpid']['value']
userState = f['flowEntryUserState']
switchState = f['flowEntrySwitchState']
match = f['flowEntryMatch'];
actions = f['flowEntryActions']
- print " FlowEntry: (%s, %s, %s, %s, %s)" % (inPort, dpid, outPort, userState, switchState)
+ print " FlowEntry: (%s, %s, %s)" % (dpid, userState, switchState)
#
# Print the match conditions