Implement OFActionSetQueue (OpenFlow 1.3 only)
Action "Set-Queue" (OFPAT_SET_QUEUE) is not yet implemented.
This patch adds such a QUEUE Treatment and implements it using the Set-Queue
action of OpenFlow 1.3.
The --setQueue parameter can be used when defining intents so that flows with
the respective Set-Queue action are installed.
This includes contributions by Michael Jarschel and Arne Schwabe and is the
result of our ONOS Hackaton project at EWSDN 2015.
Change-Id: Ie7bf01e8fd90fe68977477327ac4f53d7930e186
diff --git a/core/api/src/main/java/org/onosproject/net/flow/DefaultTrafficTreatment.java b/core/api/src/main/java/org/onosproject/net/flow/DefaultTrafficTreatment.java
index a628725..6174cef 100644
--- a/core/api/src/main/java/org/onosproject/net/flow/DefaultTrafficTreatment.java
+++ b/core/api/src/main/java/org/onosproject/net/flow/DefaultTrafficTreatment.java
@@ -237,6 +237,7 @@
case NOACTION:
case OUTPUT:
case GROUP:
+ case QUEUE:
case L0MODIFICATION:
case L2MODIFICATION:
case L3MODIFICATION:
@@ -381,6 +382,11 @@
}
@Override
+ public Builder setQueue(long queueId) {
+ return add(Instructions.setQueue(queueId));
+ }
+
+ @Override
public TrafficTreatment.Builder meter(MeterId meterId) {
return add(Instructions.meterTraffic(meterId));
}