<!-- Sonar properties using jacoco to retrieve integration test results -->
<sonar.java.coveragePlugin>jacoco</sonar.java.coveragePlugin>
<sonar.language>java</sonar.language>
+ <forwardingrulesmanager.version>0.5.0-SNAPSHOT</forwardingrulesmanager.version>
</properties>
<dependencyManagement>
<dependency>
<groupId>org.opendaylight.controller</groupId>
<artifactId>forwardingrulesmanager</artifactId>
- <version>${controller.version}</version>
+ <version>${forwardingrulesmanager.version}</version>
</dependency>
<dependency>
<groupId>org.opendaylight.controller</groupId>
</scm>
<artifactId>forwardingrulesmanager</artifactId>
- <version>0.4.1-SNAPSHOT</version>
+ <version>0.5.0-SNAPSHOT</version>
<packaging>bundle</packaging>
<build>
public PortGroupProvider getPortGroupProvider();
+ /**
+ * Returns the list of Flow entries for a network node.
+ * This list contains the flows as they were
+ * requested to be installed by the applications, before any merging with
+ * container flow is done.
+ *
+ * @param node
+ * @return the original list of flow entries belonging to the specified node
+ */
+ public List<FlowEntry> getFlowEntriesForNode(Node node);
+
+ /**
+ * Returns the list of Flow entries installed in a network node.
+ * This list contains the effective flows installed
+ * on the nodes after the merging with any possible container flow was performed.
+ * If no container flow are specified, this method returns the same list as returned
+ * by getFlowEntriesForNode(Node node).
+ *
+ * @param node
+ * @return the list of container flow merged flow entries belonging to the specified node
+ */
+ public List<FlowEntry> getInstalledFlowEntriesForNode(Node node);
+
}
<dependency>
<groupId>org.opendaylight.controller</groupId>
<artifactId>forwardingrulesmanager</artifactId>
- <version>0.4.1-SNAPSHOT</version>
+ <version>0.5.0-SNAPSHOT</version>
</dependency>
<dependency>
<groupId>junit</groupId>
* Do nothing
*/
}
+
+ /**
+ * {@inheritDoc}
+ */
+ @Override
+ public List<FlowEntry> getFlowEntriesForNode(Node node) {
+ List<FlowEntry> list = new ArrayList<FlowEntry>();
+ if (node != null) {
+ for (Map.Entry<FlowEntry, FlowEntry> entry : this.originalSwView.entrySet()) {
+ if (node.equals(entry.getKey().getNode())) {
+ list.add(entry.getKey().clone());
+ }
+ }
+ }
+ return list;
+ }
+
+ /**
+ * {@inheritDoc}
+ */
+ @Override
+ public List<FlowEntry> getInstalledFlowEntriesForNode(Node node) {
+ List<FlowEntry> list = new ArrayList<FlowEntry>();
+ if (node != null) {
+ List<FlowEntryInstall> flowEntryInstallList = this.nodeFlows.get(node);
+ if(flowEntryInstallList != null) {
+ for(FlowEntryInstall fi: flowEntryInstallList) {
+ list.add(fi.getInstall().clone());
+ }
+ }
+ }
+ return list;
+ }
}
<dependency>
<groupId>org.opendaylight.controller</groupId>
<artifactId>forwardingrulesmanager</artifactId>
- <version>0.4.1-SNAPSHOT</version>
+ <version>0.5.0-SNAPSHOT</version>
</dependency>
<dependency>
<groupId>org.opendaylight.controller</groupId>
<dependency>
<groupId>org.opendaylight.controller</groupId>
<artifactId>forwardingrulesmanager</artifactId>
- <version>0.4.1-SNAPSHOT</version>
+ <version>0.5.0-SNAPSHOT</version>
</dependency>
<dependency>
<groupId>org.opendaylight.controller</groupId>