BUG-2658: Remove adsal and migrate to mdsal 17/14617/5
authorSam Hague <shague@redhat.com>
Thu, 29 Jan 2015 23:36:18 +0000 (18:36 -0500)
committerSam Hague <shague@redhat.com>
Fri, 30 Jan 2015 21:51:08 +0000 (16:51 -0500)
This commit covers removing adsal-compatibility.

patchset 2: Remove adsal-compatibility from ovs-sfc features
patchset 3: Really remove the adsal-compatibility from ovs-sfc features.
patchset 4: Apparently not
patchset 5: Trying again

Change-Id: I7f011820488a1fa4a1e29967cf251640562e0b89
Signed-off-by: Sam Hague <shague@redhat.com>
features/ovs-sfc/pom.xml
features/ovs-sfc/src/main/resources/features.xml
features/ovsdb/pom.xml
features/ovsdb/src/main/resources/features.xml
utils/mdsal-openflow/pom.xml
utils/mdsal-openflow/src/main/java/org/opendaylight/ovsdb/utils/mdsal/openflow/InstructionUtils.java

index 7656efef752c22f20733a76d9748dd90ae149f34..1014fbb009f3d669f13a239831b9282cccc7bbab 100644 (file)
       <classifier>features</classifier>
       <type>xml</type>
     </dependency>
-    <dependency>
-      <groupId>org.opendaylight.controller</groupId>
-      <artifactId>features-adsal-compatibility</artifactId>
-      <version>${odl.karaf.base.version}</version>
-      <classifier>features</classifier>
-      <type>xml</type>
-    </dependency>
     <dependency>
       <groupId>org.opendaylight.openflowplugin</groupId>
       <artifactId>features-openflowplugin-extension</artifactId>
index b94dc7e6ddffad058c868f9571e54577dd886de7..f1bdb41029c331c5cddf8004edcb0c27462c62ed 100644 (file)
@@ -4,7 +4,6 @@
           xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
           xsi:schemaLocation="http://karaf.apache.org/xmlns/features/v1.2.0 http://karaf.apache.org/xmlns/features/v1.2.0">
     <repository>mvn:org.opendaylight.controller/features-nsf/${nsf.version}/xml/features</repository>
-    <repository>mvn:org.opendaylight.controller/features-adsal-compatibility/${odl.karaf.base.version}/xml/features</repository>
     <repository>mvn:org.opendaylight.openflowplugin/features-openflowplugin-extension/${openflowplugin.version}/xml/features</repository>
     <repository>mvn:org.opendaylight.ovsdb/features-ovsdb/${ovsdb.library.version}/xml/features</repository>
     <repository>mvn:org.opendaylight.sfc/features-sfc/0.1.0-SNAPSHOT/xml/features</repository>
@@ -15,7 +14,6 @@
         <feature version="${ovsdb.plugin.version}">odl-ovsdb-plugin</feature>
         <feature version="${openflowplugin.version}">odl-openflowplugin-nxm-extensions</feature>
         <feature version="${nsf.version}">odl-nsf-all</feature>
-        <feature version="${sal.version}">odl-adsal-compatibility</feature>
         <feature version='0.1.0-SNAPSHOT'>odl-sfc-provider</feature>
         <feature version='0.1.0-SNAPSHOT'>odl-sfc-model</feature>
         <bundle>mvn:org.opendaylight.ovsdb/ovssfc/${ovsdb.ovssfc.version}</bundle>
index 67bbfbc34d385d92f2ebf48230ce07ce4c5f6949..519177104b0d25941b3cdcce165211c30e06e396 100644 (file)
       <classifier>features</classifier>
       <type>xml</type>
     </dependency>
-    <dependency>
-      <groupId>org.opendaylight.controller</groupId>
-      <artifactId>features-adsal-compatibility</artifactId>
-      <version>${odl.karaf.base.version}</version>
-      <classifier>features</classifier>
-      <type>xml</type>
-    </dependency>
     <dependency>
       <groupId>org.opendaylight.controller</groupId>
       <artifactId>features-nsf</artifactId>
index dfae2a42d157a4b47cef2bdb5fd95053f2c4e51e..c0de5c5b8f258437e3e2a1c078b64c45ba64a5c7 100644 (file)
@@ -2,7 +2,6 @@
 <features name="ovsdb-${project.version}" xmlns="http://karaf.apache.org/xmlns/features/v1.2.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://karaf.apache.org/xmlns/features/v1.2.0 http://karaf.apache.org/xmlns/features/v1.2.0">
     <repository>mvn:org.opendaylight.controller/features-base/${odl.karaf.base.version}/xml/features</repository>
     <repository>mvn:org.opendaylight.controller/features-adsal/${sal.version}/xml/features</repository>
-    <repository>mvn:org.opendaylight.controller/features-adsal-compatibility/${odl.karaf.base.version}/xml/features</repository>
     <repository>mvn:org.opendaylight.controller/features-nsf/${nsf.version}/xml/features</repository>
     <repository>mvn:org.opendaylight.openflowplugin/features-openflowplugin-extension/${openflowplugin.version}/xml/features</repository>
     <repository>mvn:org.opendaylight.openflowplugin/features-openflowplugin/${openflowplugin.version}/xml/features</repository>
@@ -51,7 +50,6 @@
         <feature version="${openflowplugin.version}">odl-openflowplugin-southbound</feature>
         <feature version="${openflowplugin.version}">odl-openflowplugin-flow-services</feature>
         <feature version="${nsf.version}">odl-nsf-all</feature>
-        <feature version="${sal.version}">odl-adsal-compatibility</feature>
         <bundle>mvn:org.opendaylight.ovsdb/openstack.net-virt/${openstack.netvirt.version}</bundle>
         <bundle>mvn:org.opendaylight.ovsdb/openstack.net-virt-providers/${openstack.netvirt.providers.version}</bundle>
     </feature>
index 29669b377fad688f604d468396536d2dad4d5dd3..34bc3b1157f988ae988b7ecc96e24347b60cbc29 100644 (file)
       <groupId>org.opendaylight.controller</groupId>
       <artifactId>sal</artifactId>
     </dependency>
-    <dependency>
-      <groupId>org.opendaylight.controller</groupId>
-      <artifactId>sal-compatibility</artifactId>
-      <version>${mdsal.version}</version>
-    </dependency>
     <dependency>
       <groupId>org.opendaylight.ovsdb</groupId>
       <artifactId>library</artifactId>
index 0f333cefa79de3abb5ff1735b7b4534c5926c73c..da480aa255f72158088f84b6c47182e6c2b1060a 100644 (file)
@@ -10,7 +10,6 @@
 package org.opendaylight.ovsdb.utils.mdsal.openflow;
 
 import static org.opendaylight.ovsdb.utils.mdsal.openflow.ActionUtils.dropAction;
-import org.opendaylight.controller.sal.compatibility.NodeMapping;
 
 import org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.inet.types.rev100924.Ipv4Prefix;
 import org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.inet.types.rev100924.PortNumber;
@@ -45,6 +44,7 @@ import org.opendaylight.yang.gen.v1.urn.opendaylight.action.types.rev131112.acti
 import org.opendaylight.yang.gen.v1.urn.opendaylight.action.types.rev131112.action.list.ActionBuilder;
 import org.opendaylight.yang.gen.v1.urn.opendaylight.action.types.rev131112.action.list.ActionKey;
 import org.opendaylight.yang.gen.v1.urn.opendaylight.action.types.rev131112.address.address.Ipv4Builder;
+import org.opendaylight.yang.gen.v1.urn.opendaylight.flow.types.rev131026.OutputPortValues;
 import org.opendaylight.yang.gen.v1.urn.opendaylight.flow.types.rev131026.flow.Instructions;
 import org.opendaylight.yang.gen.v1.urn.opendaylight.flow.types.rev131026.flow.InstructionsBuilder;
 import org.opendaylight.yang.gen.v1.urn.opendaylight.flow.types.rev131026.instruction.instruction.ApplyActionsCase;
@@ -97,7 +97,9 @@ public class InstructionUtils {
 
         OutputActionBuilder output = new OutputActionBuilder();
         output.setMaxLength(MAX_LENGTH);
-        output.setOutputNodeConnector(NodeMapping.toControllerNodeConnectorId(new NodeId(nodeName)));
+        NodeId nodeId = new NodeId(nodeName);
+        output.setOutputNodeConnector(new NodeConnectorId(nodeId.getValue() + ":"
+                + OutputPortValues.CONTROLLER.toString()));
         ab.setAction(new OutputActionCaseBuilder().setOutputAction(output.build()).build());
         ab.setOrder(0);
         ab.setKey(new ActionKey(0));
@@ -116,18 +118,20 @@ public class InstructionUtils {
     /**
      * Create NORMAL Reserved Port Instruction (packet_in)
      *
-     * @param nodeId Uri Prefix, containing nodeConnectorType and dpId (aka NodeId)
+     * @param nodeName Uri Prefix, containing nodeConnectorType and dpId (aka NodeId)
      * @param ib Map InstructionBuilder without any instructions
      * @return ib Map InstructionBuilder with instructions
      */
 
-    public static InstructionBuilder createNormalInstructions(String nodeId, InstructionBuilder ib) {
+    public static InstructionBuilder createNormalInstructions(String nodeName, InstructionBuilder ib) {
 
         List<Action> actionList = Lists.newArrayList();
         ActionBuilder ab = new ActionBuilder();
 
         OutputActionBuilder output = new OutputActionBuilder();
-        output.setOutputNodeConnector(NodeMapping.toNormalNodeConnectorId(new NodeId(nodeId)));
+        NodeId nodeId = new NodeId(nodeName);
+        output.setOutputNodeConnector(new NodeConnectorId(nodeId.getValue() + ":"
+                + OutputPortValues.NORMAL.toString()));
         ab.setAction(new OutputActionCaseBuilder().setOutputAction(output.build()).build());
         ab.setOrder(0);
         ab.setKey(new ActionKey(0));