summaryrefslogtreecommitdiffstats
path: root/sdnr/wt/devicemanager-onap
diff options
context:
space:
mode:
Diffstat (limited to 'sdnr/wt/devicemanager-onap')
-rw-r--r--sdnr/wt/devicemanager-onap/adapter-manager/feature/pom.xml3
-rwxr-xr-xsdnr/wt/devicemanager-onap/adapter-manager/installer/pom.xml3
-rw-r--r--sdnr/wt/devicemanager-onap/adapter-manager/model/pom.xml3
-rwxr-xr-xsdnr/wt/devicemanager-onap/adapter-manager/pom.xml3
-rw-r--r--sdnr/wt/devicemanager-onap/adapter-manager/provider/pom.xml21
-rw-r--r--sdnr/wt/devicemanager-onap/onf12/feature/pom.xml3
-rwxr-xr-xsdnr/wt/devicemanager-onap/onf12/installer/pom.xml3
-rw-r--r--sdnr/wt/devicemanager-onap/onf12/model/pom.xml3
-rwxr-xr-xsdnr/wt/devicemanager-onap/onf12/pom.xml3
-rw-r--r--sdnr/wt/devicemanager-onap/onf12/provider/pom.xml36
-rw-r--r--sdnr/wt/devicemanager-onap/onf12/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/onf/ifpac/equipment/ExtendedEquipment.java5
-rw-r--r--sdnr/wt/devicemanager-onap/onf14/feature/pom.xml3
-rwxr-xr-xsdnr/wt/devicemanager-onap/onf14/installer/pom.xml3
-rw-r--r--sdnr/wt/devicemanager-onap/onf14/model/pom.xml3
-rwxr-xr-xsdnr/wt/devicemanager-onap/onf14/pom.xml3
-rw-r--r--sdnr/wt/devicemanager-onap/onf14/provider/pom.xml38
-rw-r--r--sdnr/wt/devicemanager-onap/onf14/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/onf14/dom/impl/dataprovider/Onf14DomToInternalDataModel.java5
-rw-r--r--sdnr/wt/devicemanager-onap/onf14/provider/src/test/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/onf14/util/Onf14DomTestUtils.java4
-rw-r--r--sdnr/wt/devicemanager-onap/onf14/provider/src/test/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/onf14/util/TestYangParserUtil.java112
-rw-r--r--sdnr/wt/devicemanager-onap/onf14/provider/src/test/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/onf14/util/YangParserTestUtils.java382
-rw-r--r--sdnr/wt/devicemanager-onap/openroadm/feature/pom.xml3
-rwxr-xr-xsdnr/wt/devicemanager-onap/openroadm/installer/pom.xml2
-rw-r--r--sdnr/wt/devicemanager-onap/openroadm/model/pom.xml3
-rwxr-xr-xsdnr/wt/devicemanager-onap/openroadm/pom.xml3
-rw-r--r--sdnr/wt/devicemanager-onap/openroadm/provider/pom.xml47
-rw-r--r--sdnr/wt/devicemanager-onap/openroadm/provider/src/test/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/openroadm/test/TestChangeNotificationListener.java7
-rw-r--r--sdnr/wt/devicemanager-onap/openroadm/provider/src/test/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/openroadm/test/TestOpenRoadmDeviceChangeNotification.java7
-rw-r--r--sdnr/wt/devicemanager-onap/openroadm/provider/src/test/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/openroadm/test/TestOpenRoadmPMDataBuilder.java9
-rw-r--r--sdnr/wt/devicemanager-onap/openroadm71/feature/pom.xml3
-rwxr-xr-xsdnr/wt/devicemanager-onap/openroadm71/installer/pom.xml2
-rw-r--r--sdnr/wt/devicemanager-onap/openroadm71/model/pom.xml3
-rwxr-xr-xsdnr/wt/devicemanager-onap/openroadm71/pom.xml3
-rw-r--r--sdnr/wt/devicemanager-onap/openroadm71/provider/pom.xml42
-rw-r--r--sdnr/wt/devicemanager-onap/openroadm71/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/openroadm71/impl/OpenroadmInventoryInput.java6
-rw-r--r--sdnr/wt/devicemanager-onap/openroadm71/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/openroadm71/impl/OpenroadmNetworkElement.java7
-rw-r--r--sdnr/wt/devicemanager-onap/openroadm71/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/openroadm71/impl/OpenroadmNetworkElementFactory.java2
-rw-r--r--sdnr/wt/devicemanager-onap/openroadm71/provider/src/main/yang/org-openroadm-device.yang6
-rw-r--r--sdnr/wt/devicemanager-onap/openroadm71/provider/src/test/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/openroadm71/test/TestChangeNotificationListener.java7
-rw-r--r--sdnr/wt/devicemanager-onap/openroadm71/provider/src/test/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/openroadm71/test/TestOpenRoadmDeviceChangeNotification.java7
-rw-r--r--sdnr/wt/devicemanager-onap/openroadm71/provider/src/test/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/openroadm71/test/TestOpenRoadmInventory.java8
-rw-r--r--sdnr/wt/devicemanager-onap/openroadm71/provider/src/test/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/openroadm71/test/TestOpenRoadmNetworkElement.java10
-rw-r--r--sdnr/wt/devicemanager-onap/openroadm71/provider/src/test/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/openroadm71/test/TestOpenRoadmNetworkElementFactory.java2
-rw-r--r--sdnr/wt/devicemanager-onap/openroadm71/provider/src/test/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/openroadm71/test/TestOpenRoadmPMDataBuilder.java9
43 files changed, 608 insertions, 229 deletions
diff --git a/sdnr/wt/devicemanager-onap/adapter-manager/feature/pom.xml b/sdnr/wt/devicemanager-onap/adapter-manager/feature/pom.xml
index e5425edb2..4a8865d0b 100644
--- a/sdnr/wt/devicemanager-onap/adapter-manager/feature/pom.xml
+++ b/sdnr/wt/devicemanager-onap/adapter-manager/feature/pom.xml
@@ -22,13 +22,14 @@
~ ============LICENSE_END=======================================================
~
-->
+
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<parent>
<groupId>org.onap.ccsdk.parent</groupId>
<artifactId>single-feature-parent</artifactId>
- <version>2.4.0</version>
+ <version>2.4.1-SNAPSHOT</version>
<relativePath/>
</parent>
diff --git a/sdnr/wt/devicemanager-onap/adapter-manager/installer/pom.xml b/sdnr/wt/devicemanager-onap/adapter-manager/installer/pom.xml
index c57d1af0a..d110338bd 100755
--- a/sdnr/wt/devicemanager-onap/adapter-manager/installer/pom.xml
+++ b/sdnr/wt/devicemanager-onap/adapter-manager/installer/pom.xml
@@ -22,13 +22,14 @@
~ ============LICENSE_END=======================================================
~
-->
+
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<parent>
<groupId>org.onap.ccsdk.parent</groupId>
<artifactId>odlparent-lite</artifactId>
- <version>2.4.0</version>
+ <version>2.4.1-SNAPSHOT</version>
<relativePath/>
</parent>
diff --git a/sdnr/wt/devicemanager-onap/adapter-manager/model/pom.xml b/sdnr/wt/devicemanager-onap/adapter-manager/model/pom.xml
index 840418add..521b43c7a 100644
--- a/sdnr/wt/devicemanager-onap/adapter-manager/model/pom.xml
+++ b/sdnr/wt/devicemanager-onap/adapter-manager/model/pom.xml
@@ -22,13 +22,14 @@
~ ============LICENSE_END=======================================================
~
-->
+
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<parent>
<groupId>org.onap.ccsdk.parent</groupId>
<artifactId>binding-parent</artifactId>
- <version>2.4.0</version>
+ <version>2.4.1-SNAPSHOT</version>
<relativePath/>
</parent>
diff --git a/sdnr/wt/devicemanager-onap/adapter-manager/pom.xml b/sdnr/wt/devicemanager-onap/adapter-manager/pom.xml
index 0b4c48502..f95768b64 100755
--- a/sdnr/wt/devicemanager-onap/adapter-manager/pom.xml
+++ b/sdnr/wt/devicemanager-onap/adapter-manager/pom.xml
@@ -22,13 +22,14 @@
~ ============LICENSE_END=======================================================
~
-->
+
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<parent>
<groupId>org.onap.ccsdk.parent</groupId>
<artifactId>odlparent-lite</artifactId>
- <version>2.4.0</version>
+ <version>2.4.1-SNAPSHOT</version>
<relativePath/>
</parent>
diff --git a/sdnr/wt/devicemanager-onap/adapter-manager/provider/pom.xml b/sdnr/wt/devicemanager-onap/adapter-manager/provider/pom.xml
index 4f98031f0..32699ddd8 100644
--- a/sdnr/wt/devicemanager-onap/adapter-manager/provider/pom.xml
+++ b/sdnr/wt/devicemanager-onap/adapter-manager/provider/pom.xml
@@ -22,13 +22,14 @@
~ ============LICENSE_END=======================================================
~
-->
+
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<parent>
<groupId>org.onap.ccsdk.parent</groupId>
<artifactId>binding-parent</artifactId>
- <version>2.4.0</version>
+ <version>2.4.1-SNAPSHOT</version>
<relativePath/>
</parent>
@@ -74,11 +75,29 @@
</dependency>
<dependency>
<groupId>${project.groupId}</groupId>
+ <artifactId>sdnr-wt-data-provider-model</artifactId>
+ <version>${project.version}</version>
+ <scope>provided</scope>
+ </dependency>
+ <dependency>
+ <groupId>${project.groupId}</groupId>
+ <artifactId>sdnr-wt-websocketmanager-model</artifactId>
+ <version>${project.version}</version>
+ <scope>provided</scope>
+ </dependency>
+ <dependency>
+ <groupId>${project.groupId}</groupId>
<artifactId>sdnr-wt-netconfnode-state-service-model</artifactId>
<version>${project.version}</version>
<scope>provided</scope>
</dependency>
<dependency>
+ <groupId>${project.groupId}</groupId>
+ <artifactId>sdnr-wt-common</artifactId>
+ <version>${project.version}</version>
+ <scope>provided</scope>
+ </dependency>
+ <dependency>
<groupId>org.opendaylight.netconf</groupId>
<artifactId>sal-netconf-connector</artifactId>
<scope>provided</scope>
diff --git a/sdnr/wt/devicemanager-onap/onf12/feature/pom.xml b/sdnr/wt/devicemanager-onap/onf12/feature/pom.xml
index 5549506f1..f25cdb9f1 100644
--- a/sdnr/wt/devicemanager-onap/onf12/feature/pom.xml
+++ b/sdnr/wt/devicemanager-onap/onf12/feature/pom.xml
@@ -22,13 +22,14 @@
~ ============LICENSE_END=======================================================
~
-->
+
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<parent>
<groupId>org.onap.ccsdk.parent</groupId>
<artifactId>single-feature-parent</artifactId>
- <version>2.4.0</version>
+ <version>2.4.1-SNAPSHOT</version>
<relativePath/>
</parent>
diff --git a/sdnr/wt/devicemanager-onap/onf12/installer/pom.xml b/sdnr/wt/devicemanager-onap/onf12/installer/pom.xml
index 9de3910f3..ad95be3b3 100755
--- a/sdnr/wt/devicemanager-onap/onf12/installer/pom.xml
+++ b/sdnr/wt/devicemanager-onap/onf12/installer/pom.xml
@@ -22,13 +22,14 @@
~ ============LICENSE_END=======================================================
~
-->
+
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<parent>
<groupId>org.onap.ccsdk.parent</groupId>
<artifactId>odlparent-lite</artifactId>
- <version>2.4.0</version>
+ <version>2.4.1-SNAPSHOT</version>
<relativePath/>
</parent>
diff --git a/sdnr/wt/devicemanager-onap/onf12/model/pom.xml b/sdnr/wt/devicemanager-onap/onf12/model/pom.xml
index fc64b649f..90574155e 100644
--- a/sdnr/wt/devicemanager-onap/onf12/model/pom.xml
+++ b/sdnr/wt/devicemanager-onap/onf12/model/pom.xml
@@ -22,13 +22,14 @@
~ ============LICENSE_END=======================================================
~
-->
+
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<parent>
<groupId>org.onap.ccsdk.parent</groupId>
<artifactId>binding-parent</artifactId>
- <version>2.4.0</version>
+ <version>2.4.1-SNAPSHOT</version>
<relativePath/>
</parent>
diff --git a/sdnr/wt/devicemanager-onap/onf12/pom.xml b/sdnr/wt/devicemanager-onap/onf12/pom.xml
index 40eb33097..8d4dd1fcb 100755
--- a/sdnr/wt/devicemanager-onap/onf12/pom.xml
+++ b/sdnr/wt/devicemanager-onap/onf12/pom.xml
@@ -22,13 +22,14 @@
~ ============LICENSE_END=======================================================
~
-->
+
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<parent>
<groupId>org.onap.ccsdk.parent</groupId>
<artifactId>odlparent-lite</artifactId>
- <version>2.4.0</version>
+ <version>2.4.1-SNAPSHOT</version>
<relativePath/>
</parent>
diff --git a/sdnr/wt/devicemanager-onap/onf12/provider/pom.xml b/sdnr/wt/devicemanager-onap/onf12/provider/pom.xml
index f86a3982f..0a5d1d5d2 100644
--- a/sdnr/wt/devicemanager-onap/onf12/provider/pom.xml
+++ b/sdnr/wt/devicemanager-onap/onf12/provider/pom.xml
@@ -22,13 +22,14 @@
~ ============LICENSE_END=======================================================
~
-->
+
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<parent>
<groupId>org.onap.ccsdk.parent</groupId>
<artifactId>binding-parent</artifactId>
- <version>2.4.0</version>
+ <version>2.4.1-SNAPSHOT</version>
<relativePath/>
</parent>
@@ -52,17 +53,22 @@
</properties>
<dependencies>
- <!-- begin for testing -->
+
<dependency>
- <groupId>org.mockito</groupId>
- <artifactId>mockito-core</artifactId>
- <scope>test</scope>
+ <groupId>${project.groupId}</groupId>
+ <artifactId>sdnr-wt-devicemanager-onap-onf12-model</artifactId>
+ <version>${project.version}</version>
+ <scope>provided</scope>
</dependency>
-
- <!-- end for testing -->
<dependency>
<groupId>${project.groupId}</groupId>
- <artifactId>sdnr-wt-devicemanager-onap-onf12-model</artifactId>
+ <artifactId>sdnr-wt-common</artifactId>
+ <version>${project.version}</version>
+ <scope>provided</scope>
+ </dependency>
+ <dependency>
+ <groupId>${project.groupId}</groupId>
+ <artifactId>sdnr-wt-data-provider-model</artifactId>
<version>${project.version}</version>
<scope>provided</scope>
</dependency>
@@ -79,10 +85,23 @@
<scope>provided</scope>
</dependency>
<dependency>
+ <groupId>${project.groupId}</groupId>
+ <artifactId>sdnr-wt-websocketmanager-model</artifactId>
+ <version>${project.version}</version>
+ <scope>provided</scope>
+ </dependency>
+ <dependency>
<groupId>org.opendaylight.netconf</groupId>
<artifactId>sal-netconf-connector</artifactId>
<scope>provided</scope>
</dependency>
+ <!-- begin for testing -->
+ <dependency>
+ <groupId>org.mockito</groupId>
+ <artifactId>mockito-core</artifactId>
+ <version>3.4.2</version>
+ <scope>test</scope>
+ </dependency>
<dependency>
<groupId>${project.groupId}</groupId>
<artifactId>sdnr-wt-yang-utils</artifactId>
@@ -94,6 +113,7 @@
<artifactId>org.osgi.core</artifactId>
<scope>test</scope>
</dependency>
+ <!-- end for testing -->
</dependencies>
<build>
diff --git a/sdnr/wt/devicemanager-onap/onf12/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/onf/ifpac/equipment/ExtendedEquipment.java b/sdnr/wt/devicemanager-onap/onf12/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/onf/ifpac/equipment/ExtendedEquipment.java
index e6c3865f7..bbdf66ce7 100644
--- a/sdnr/wt/devicemanager-onap/onf12/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/onf/ifpac/equipment/ExtendedEquipment.java
+++ b/sdnr/wt/devicemanager-onap/onf12/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/onf/ifpac/equipment/ExtendedEquipment.java
@@ -19,7 +19,10 @@ package org.onap.ccsdk.features.sdnr.wt.devicemanager.onf.ifpac.equipment;
import java.util.ArrayList;
import java.util.Collection;
+import java.util.HashSet;
import java.util.List;
+import java.util.Set;
+
import org.onap.ccsdk.features.sdnr.wt.common.YangHelper;
import org.opendaylight.yang.gen.v1.urn.onf.params.xml.ns.yang.core.model.rev170320.Equipment;
import org.opendaylight.yang.gen.v1.urn.onf.params.xml.ns.yang.core.model.rev170320.equipment.g.ContainedHolder;
@@ -91,7 +94,7 @@ public class ExtendedEquipment {
if (getEquipment() != null) {
inventoryBuilder.setUuid(getEquipment().getUuid().getValue());
// -- String list with ids of holders
- List<String> containerHolderKeyList = new ArrayList<>();
+ Set<String> containerHolderKeyList = new HashSet<>();
Collection<ContainedHolder> containerHolderList = YangHelper.getCollection(getEquipment().getContainedHolder());
if (containerHolderList != null) {
for (ContainedHolder containerHolder : containerHolderList) {
diff --git a/sdnr/wt/devicemanager-onap/onf14/feature/pom.xml b/sdnr/wt/devicemanager-onap/onf14/feature/pom.xml
index b935690c5..d1598adca 100644
--- a/sdnr/wt/devicemanager-onap/onf14/feature/pom.xml
+++ b/sdnr/wt/devicemanager-onap/onf14/feature/pom.xml
@@ -22,13 +22,14 @@
~ ============LICENSE_END=======================================================
~
-->
+
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<parent>
<groupId>org.onap.ccsdk.parent</groupId>
<artifactId>single-feature-parent</artifactId>
- <version>2.4.0</version>
+ <version>2.4.1-SNAPSHOT</version>
<relativePath/>
</parent>
diff --git a/sdnr/wt/devicemanager-onap/onf14/installer/pom.xml b/sdnr/wt/devicemanager-onap/onf14/installer/pom.xml
index 23da17b80..74474ea20 100755
--- a/sdnr/wt/devicemanager-onap/onf14/installer/pom.xml
+++ b/sdnr/wt/devicemanager-onap/onf14/installer/pom.xml
@@ -22,13 +22,14 @@
~ ============LICENSE_END=======================================================
~
-->
+
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<parent>
<groupId>org.onap.ccsdk.parent</groupId>
<artifactId>odlparent-lite</artifactId>
- <version>2.4.0</version>
+ <version>2.4.1-SNAPSHOT</version>
<relativePath/>
</parent>
diff --git a/sdnr/wt/devicemanager-onap/onf14/model/pom.xml b/sdnr/wt/devicemanager-onap/onf14/model/pom.xml
index 35c38a0c6..6bec8692f 100644
--- a/sdnr/wt/devicemanager-onap/onf14/model/pom.xml
+++ b/sdnr/wt/devicemanager-onap/onf14/model/pom.xml
@@ -22,13 +22,14 @@
~ ============LICENSE_END=======================================================
~
-->
+
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<parent>
<groupId>org.onap.ccsdk.parent</groupId>
<artifactId>binding-parent</artifactId>
- <version>2.4.0</version>
+ <version>2.4.1-SNAPSHOT</version>
<relativePath/>
</parent>
diff --git a/sdnr/wt/devicemanager-onap/onf14/pom.xml b/sdnr/wt/devicemanager-onap/onf14/pom.xml
index 48cc2b802..ec810996d 100755
--- a/sdnr/wt/devicemanager-onap/onf14/pom.xml
+++ b/sdnr/wt/devicemanager-onap/onf14/pom.xml
@@ -22,13 +22,14 @@
~ ============LICENSE_END=======================================================
~
-->
+
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<parent>
<groupId>org.onap.ccsdk.parent</groupId>
<artifactId>odlparent-lite</artifactId>
- <version>2.4.0</version>
+ <version>2.4.1-SNAPSHOT</version>
<relativePath/>
</parent>
diff --git a/sdnr/wt/devicemanager-onap/onf14/provider/pom.xml b/sdnr/wt/devicemanager-onap/onf14/provider/pom.xml
index b1040dedd..4714fe94c 100644
--- a/sdnr/wt/devicemanager-onap/onf14/provider/pom.xml
+++ b/sdnr/wt/devicemanager-onap/onf14/provider/pom.xml
@@ -22,13 +22,14 @@
~ ============LICENSE_END=======================================================
~
-->
+
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<parent>
<groupId>org.onap.ccsdk.parent</groupId>
<artifactId>binding-parent</artifactId>
- <version>2.4.0</version>
+ <version>2.4.1-SNAPSHOT</version>
<relativePath/>
</parent>
@@ -53,14 +54,6 @@
</properties>
<dependencies>
- <!-- begin for testing -->
- <dependency>
- <groupId>org.mockito</groupId>
- <artifactId>mockito-core</artifactId>
- <scope>test</scope>
- </dependency>
-
- <!-- end for testing -->
<dependency>
<groupId>${project.groupId}</groupId>
<artifactId>sdnr-wt-devicemanager-onap-onf14-model</artifactId>
@@ -71,8 +64,26 @@
<artifactId>sdnr-wt-devicemanager-core-model</artifactId>
<version>${project.version}</version>
<scope>provided</scope>
+ </dependency>
+ <dependency>
+ <groupId>${project.groupId}</groupId>
+ <artifactId>sdnr-wt-websocketmanager-model</artifactId>
+ <version>${project.version}</version>
+ <scope>provided</scope>
+ </dependency>
+ <dependency>
+ <groupId>${project.groupId}</groupId>
+ <artifactId>sdnr-wt-data-provider-model</artifactId>
+ <version>${project.version}</version>
+ <scope>provided</scope>
</dependency>
<dependency>
+ <groupId>${project.groupId}</groupId>
+ <artifactId>sdnr-wt-common</artifactId>
+ <version>${project.version}</version>
+ <scope>provided</scope>
+ </dependency>
+ <dependency>
<groupId>org.opendaylight.mdsal</groupId>
<artifactId>mdsal-binding-dom-codec-api</artifactId>
<scope>provided</scope>
@@ -86,7 +97,6 @@
<dependency>
<groupId>org.opendaylight.netconf</groupId>
<artifactId>sal-netconf-connector</artifactId>
- <version>2.0.4</version>
<scope>provided</scope>
</dependency>
<dependency>
@@ -99,6 +109,13 @@
<artifactId>rfc6991-ietf-yang-types</artifactId>
<scope>provided</scope>
</dependency>
+ <!-- begin for testing -->
+ <dependency>
+ <groupId>org.mockito</groupId>
+ <artifactId>mockito-core</artifactId>
+ <scope>test</scope>
+ </dependency>
+ <!-- end for testing -->
</dependencies>
<build>
@@ -112,6 +129,7 @@
<plugin>
<groupId>org.opendaylight.yangtools</groupId>
<artifactId>yang-maven-plugin</artifactId>
+ <version>7.0.9</version>
<executions>
<execution>
<id>binding</id>
diff --git a/sdnr/wt/devicemanager-onap/onf14/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/onf14/dom/impl/dataprovider/Onf14DomToInternalDataModel.java b/sdnr/wt/devicemanager-onap/onf14/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/onf14/dom/impl/dataprovider/Onf14DomToInternalDataModel.java
index 8a75bbc11..2a931378f 100644
--- a/sdnr/wt/devicemanager-onap/onf14/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/onf14/dom/impl/dataprovider/Onf14DomToInternalDataModel.java
+++ b/sdnr/wt/devicemanager-onap/onf14/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/onf14/dom/impl/dataprovider/Onf14DomToInternalDataModel.java
@@ -2,8 +2,11 @@ package org.onap.ccsdk.features.sdnr.wt.devicemanager.onf14.dom.impl.dataprovide
import java.util.ArrayList;
import java.util.Collection;
+import java.util.HashSet;
import java.util.List;
import java.util.Objects;
+import java.util.Set;
+
import org.onap.ccsdk.features.sdnr.wt.devicemanager.onf14.dom.impl.util.Onf14DMDOMUtility;
import org.onap.ccsdk.features.sdnr.wt.devicemanager.onf14.dom.impl.util.Onf14DevicemanagerQNames;
import org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.data.provider.rev201110.Inventory;
@@ -35,7 +38,7 @@ public class Onf14DomToInternalDataModel {
inventoryBuilder.setUuid(Onf14DMDOMUtility.getUuidFromEquipment(currentEq));
inventoryBuilder.setParentUuid(parentUuid);
- List<String> containedHolderKeyList = new ArrayList<>();
+ Set<String> containedHolderKeyList = new HashSet<>();
MapNode containedHolderMap = (MapNode) currentEq
.childByArg(new NodeIdentifier(Onf14DevicemanagerQNames.CORE_MODEL_CC_EQPT_CONTAINED_HOLDER));
if (containedHolderMap != null) {
diff --git a/sdnr/wt/devicemanager-onap/onf14/provider/src/test/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/onf14/util/Onf14DomTestUtils.java b/sdnr/wt/devicemanager-onap/onf14/provider/src/test/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/onf14/util/Onf14DomTestUtils.java
index ad79a5c43..6dc9b50b5 100644
--- a/sdnr/wt/devicemanager-onap/onf14/provider/src/test/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/onf14/util/Onf14DomTestUtils.java
+++ b/sdnr/wt/devicemanager-onap/onf14/provider/src/test/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/onf14/util/Onf14DomTestUtils.java
@@ -82,7 +82,7 @@ public class Onf14DomTestUtils {
public static NormalizedNode getNormalizedNodeFromJson() throws IOException, URISyntaxException {
- schemaContext = TestYangParserUtil.parseYangResourceDirectory("/");
+ schemaContext = YangParserTestUtils.parseYangResourceDirectory("/");
lhotkaCodecFactory = JSONCodecFactorySupplier.DRAFT_LHOTKA_NETMOD_YANG_JSON_02.getShared(schemaContext);
streamAsString =
loadTextFile(new File(Onf14DomTestUtils.class.getResource("/ControlConstruct-data-test.json").toURI()));
@@ -105,7 +105,7 @@ public class Onf14DomTestUtils {
public static NormalizedNode getNormalizedNodeFromXML()
throws XMLStreamException, URISyntaxException, IOException, SAXException {
- schemaContext = TestYangParserUtil.parseYangResourceDirectory("/");
+ schemaContext = YangParserTestUtils.parseYangResourceDirectory("/");
hwContainerSchema = Inference.ofDataTreePath(schemaContext, CORE_MODEL_CONTROL_CONSTRUCT_CONTAINER);
final InputStream resourceAsStream =
Onf14DomTestUtils.class.getResourceAsStream("/ControlConstruct-data-test.xml");
diff --git a/sdnr/wt/devicemanager-onap/onf14/provider/src/test/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/onf14/util/TestYangParserUtil.java b/sdnr/wt/devicemanager-onap/onf14/provider/src/test/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/onf14/util/TestYangParserUtil.java
deleted file mode 100644
index a0cfa6760..000000000
--- a/sdnr/wt/devicemanager-onap/onf14/provider/src/test/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/onf14/util/TestYangParserUtil.java
+++ /dev/null
@@ -1,112 +0,0 @@
-/*
- * ============LICENSE_START=======================================================
- * ONAP : ccsdk features
- * ================================================================================
- * Copyright (C) 2022 highstreet technologies GmbH Intellectual Property.
- * All rights reserved.
- * ================================================================================
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- * ============LICENSE_END=========================================================
- *
- */
-package org.onap.ccsdk.features.sdnr.wt.devicemanager.onf14.util;
-
-import java.io.File;
-import java.io.FileFilter;
-import java.io.IOException;
-import java.net.URI;
-import java.net.URISyntaxException;
-import java.util.Arrays;
-import java.util.Collection;
-import java.util.Iterator;
-import java.util.ServiceLoader;
-import java.util.Set;
-import java.util.stream.Collectors;
-
-import org.eclipse.jdt.annotation.NonNull;
-import org.opendaylight.yangtools.yang.common.QName;
-import org.opendaylight.yangtools.yang.common.YangConstants;
-import org.opendaylight.yangtools.yang.model.api.EffectiveModelContext;
-import org.opendaylight.yangtools.yang.model.repo.api.SchemaSourceRepresentation;
-import org.opendaylight.yangtools.yang.model.repo.api.YangTextSchemaSource;
-import org.opendaylight.yangtools.yang.parser.api.YangParser;
-import org.opendaylight.yangtools.yang.parser.api.YangParserConfiguration;
-import org.opendaylight.yangtools.yang.parser.api.YangParserException;
-import org.opendaylight.yangtools.yang.parser.api.YangParserFactory;
-import org.opendaylight.yangtools.yang.parser.api.YangSyntaxErrorException;
-
-public final class TestYangParserUtil {
-
- private static final FileFilter YANG_FILE_FILTER = file -> {
- final String name = file.getName();
- return name.endsWith(YangConstants.RFC6020_YANG_FILE_EXTENSION) && file.isFile();
- };
-
- private static final @NonNull YangParserFactory PARSER_FACTORY;
-
- static {
- final Iterator<@NonNull YangParserFactory> it = ServiceLoader.load(YangParserFactory.class).iterator();
- if (!it.hasNext()) {
- throw new IllegalStateException("No YangParserFactory found");
- }
- PARSER_FACTORY = it.next();
- }
-
- public static EffectiveModelContext parseYangFiles(final YangParserConfiguration config, final File... files) {
- return parseYangFiles(config, Arrays.asList(files));
- }
-
- public static EffectiveModelContext parseYangFiles(final YangParserConfiguration config,
- final Collection<File> files) {
- return parseSources(config, files.stream().map(YangTextSchemaSource::forFile).collect(Collectors.toList()));
- }
-
- public static EffectiveModelContext parseYangResourceDirectory(final String resourcePath) {
- return parseYangResourceDirectory(resourcePath, YangParserConfiguration.DEFAULT);
- }
-
- public static EffectiveModelContext parseYangResourceDirectory(final String resourcePath,
- final YangParserConfiguration config) {
- final URI directoryPath;
- try {
- directoryPath = TestYangParserUtil.class.getResource(resourcePath).toURI();
- } catch (URISyntaxException e) {
- throw new IllegalArgumentException("Failed to open resource " + resourcePath, e);
- }
- return parseYangFiles(config, new File(directoryPath).listFiles(YANG_FILE_FILTER));
- }
-
- public static EffectiveModelContext parseYangSources(final YangParserConfiguration config,
- final Set<QName> supportedFeatures, final YangTextSchemaSource... sources) {
- return parseSources(config, Arrays.asList(sources));
- }
-
- public static EffectiveModelContext parseSources(final YangParserConfiguration config,
- final Collection<? extends SchemaSourceRepresentation> sources) {
- final YangParser parser = PARSER_FACTORY.createParser(config);
-
- try {
- parser.addSources(sources);
- } catch (YangSyntaxErrorException e) {
- throw new IllegalArgumentException("Malformed source", e);
- } catch (IOException e) {
- throw new IllegalArgumentException("Failed to read a source", e);
- }
-
- try {
- return parser.buildEffectiveModel();
- } catch (YangParserException e) {
- throw new IllegalStateException("Failed to assemble SchemaContext", e);
- }
- }
-}
diff --git a/sdnr/wt/devicemanager-onap/onf14/provider/src/test/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/onf14/util/YangParserTestUtils.java b/sdnr/wt/devicemanager-onap/onf14/provider/src/test/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/onf14/util/YangParserTestUtils.java
new file mode 100644
index 000000000..ee20dccae
--- /dev/null
+++ b/sdnr/wt/devicemanager-onap/onf14/provider/src/test/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/onf14/util/YangParserTestUtils.java
@@ -0,0 +1,382 @@
+/*
+ * Copyright (c) 2016 Cisco Systems, Inc. and others. All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+package org.onap.ccsdk.features.sdnr.wt.devicemanager.onf14.util;
+
+import com.google.common.annotations.Beta;
+import java.io.File;
+import java.io.FileFilter;
+import java.io.IOException;
+import java.net.URI;
+import java.net.URISyntaxException;
+import java.nio.file.Path;
+import java.util.ArrayList;
+import java.util.Arrays;
+import java.util.Collection;
+import java.util.Iterator;
+import java.util.List;
+import java.util.Locale;
+import java.util.ServiceLoader;
+import java.util.Set;
+import java.util.stream.Collectors;
+import org.eclipse.jdt.annotation.NonNull;
+import org.opendaylight.yangtools.yang.common.QName;
+import org.opendaylight.yangtools.yang.common.YangConstants;
+import org.opendaylight.yangtools.yang.model.api.EffectiveModelContext;
+import org.opendaylight.yangtools.yang.parser.api.YangParser;
+import org.opendaylight.yangtools.yang.parser.api.YangParserConfiguration;
+import org.opendaylight.yangtools.yang.parser.api.YangParserException;
+import org.opendaylight.yangtools.yang.parser.api.YangParserFactory;
+import org.opendaylight.yangtools.yang.parser.api.YangSyntaxErrorException;
+import org.opendaylight.yangtools.yang.model.repo.api.SchemaSourceRepresentation;
+import org.opendaylight.yangtools.yang.model.repo.api.YangTextSchemaSource;
+import edu.umd.cs.findbugs.annotations.SuppressFBWarnings;
+
+/**
+ * Utility class which provides convenience methods for producing effective schema context based on the supplied
+ * yang/yin sources or paths to these sources.
+ */
+@Beta
+public final class YangParserTestUtils {
+
+ private static final FileFilter YANG_FILE_FILTER = file -> {
+ // Locale keeps SpotBugs happy. It should not matter that much anyway.
+ final String name = file.getName().toLowerCase(Locale.ENGLISH);
+ return name.endsWith(YangConstants.RFC6020_YANG_FILE_EXTENSION) && file.isFile();
+ };
+
+ private static final @NonNull YangParserFactory PARSER_FACTORY;
+
+ static {
+ final Iterator<@NonNull YangParserFactory> it = ServiceLoader.load(YangParserFactory.class).iterator();
+ if (!it.hasNext()) {
+ throw new IllegalStateException("No YangParserFactory found");
+ }
+ PARSER_FACTORY = it.next();
+ }
+
+ private YangParserTestUtils() {
+ // Hidden on purpose
+ }
+
+ /**
+ * Creates a new effective schema context containing the specified YANG source. Statement parser mode is set to
+ * default mode and all YANG features are supported.
+ *
+ * @param resource relative path to the YANG file to be parsed
+ *
+ * @return effective schema context
+ */
+ public static EffectiveModelContext parseYangResource(final String resource) {
+ return parseYangResource(resource, YangParserConfiguration.DEFAULT);
+ }
+
+ /**
+ * Creates a new effective schema context containing the specified YANG source. All YANG features are supported.
+ *
+ * @param resource relative path to the YANG file to be parsed
+ * @param parserMode mode of statement parser
+ * @return effective schema context
+ */
+ public static EffectiveModelContext parseYangResource(final String resource, final YangParserConfiguration config) {
+ return parseYangResource(resource, config, null);
+ }
+
+ /**
+ * Creates a new effective schema context containing the specified YANG source. Statement parser mode is set to
+ * default mode.
+ *
+ * @param resource relative path to the YANG file to be parsed
+ * @param supportedFeatures set of supported features based on which all if-feature statements in the parsed YANG
+ * model are resolved
+ * @return effective schema context
+ */
+ public static EffectiveModelContext parseYangResource(final String resource, final Set<QName> supportedFeatures) {
+ return parseYangResource(resource, YangParserConfiguration.DEFAULT, supportedFeatures);
+ }
+
+ /**
+ * Creates a new effective schema context containing the specified YANG source.
+ *
+ * @param resource relative path to the YANG file to be parsed
+ * @param supportedFeatures set of supported features based on which all if-feature statements in the parsed YANG
+ * model are resolved
+ * @param parserMode mode of statement parser
+ * @return effective schema context
+ */
+ public static EffectiveModelContext parseYangResource(final String resource, final YangParserConfiguration config,
+ final Set<QName> supportedFeatures) {
+ final YangTextSchemaSource source = YangTextSchemaSource.forResource(YangParserTestUtils.class, resource);
+ return parseYangSources(config, supportedFeatures, source);
+ }
+
+ /**
+ * Creates a new effective schema context containing the specified YANG sources. Statement parser mode is set to
+ * default mode and all YANG features are supported.
+ *
+ * @param files YANG files to be parsed
+ * @return effective schema context
+ */
+ public static EffectiveModelContext parseYangFiles(final File... files) {
+ return parseYangFiles(Arrays.asList(files));
+ }
+
+ /**
+ * Creates a new effective schema context containing the specified YANG sources. Statement parser mode is set to
+ * default mode and all YANG features are supported.
+ *
+ * @param files collection of YANG files to be parsed
+ * @return effective schema context
+ */
+ public static EffectiveModelContext parseYangFiles(final Collection<File> files) {
+ return parseYangFiles(YangParserConfiguration.DEFAULT, files);
+ }
+
+ /**
+ * Creates a new effective schema context containing the specified YANG sources. Statement parser mode is set to
+ * default mode.
+ *
+ * @param supportedFeatures set of supported features based on which all if-feature statements in the parsed YANG
+ * models are resolved
+ * @param files YANG files to be parsed
+ * @return effective schema context
+ */
+ public static EffectiveModelContext parseYangFiles(final Set<QName> supportedFeatures, final File... files) {
+ return parseYangFiles(supportedFeatures, Arrays.asList(files));
+ }
+
+ public static EffectiveModelContext parseYangFiles(final Set<QName> supportedFeatures,
+ final Collection<File> files) {
+ return parseYangFiles(supportedFeatures, YangParserConfiguration.DEFAULT, files.stream().map(e->e.toPath()).collect(Collectors.toList()));
+ }
+
+ /**
+ * Creates a new effective schema context containing the specified YANG sources. All YANG features are supported.
+ *
+ * @param parserMode mode of statement parser
+ * @param files YANG files to be parsed
+ * @return effective schema context
+ */
+ public static EffectiveModelContext parseYangFiles(final YangParserConfiguration config, final File... files) {
+ return parseYangFiles(config, Arrays.asList(files));
+ }
+
+ /**
+ * Creates a new effective schema context containing the specified YANG sources. All YANG features are supported.
+ *
+ * @param parserMode mode of statement parser
+ * @param files collection of YANG files to be parsed
+ * @return effective schema context
+ */
+ public static EffectiveModelContext parseYangFiles(final YangParserConfiguration config,
+ final Collection<File> files) {
+ return parseYangFiles(null, config, files.stream().map(e->e.toPath()).collect(Collectors.toList()));
+ }
+
+ /**
+ * Creates a new effective schema context containing the specified YANG sources.
+ *
+ * @param supportedFeatures set of supported features based on which all if-feature statements in the parsed YANG
+ * models are resolved
+ * @param parserMode mode of statement parser
+ * @param files YANG files to be parsed
+ * @return effective schema context
+ */
+ public static EffectiveModelContext parseYangFiles(final Set<QName> supportedFeatures,
+ final YangParserConfiguration config, final Path... files) {
+ return parseYangFiles(supportedFeatures, config, Arrays.asList(files));
+ }
+
+ /**
+ * Creates a new effective schema context containing the specified YANG sources.
+ *
+ * @param supportedFeatures set of supported features based on which all if-feature statements in the parsed YANG
+ * models are resolved
+ * @param parserMode mode of statement parser
+ * @param files YANG files to be parsed
+ * @return effective schema context
+ */
+ public static EffectiveModelContext parseYangFiles(final Set<QName> supportedFeatures,
+ final YangParserConfiguration config, final Collection<Path> files) {
+ return parseSources(config, supportedFeatures,
+ files.stream().map(YangTextSchemaSource::forPath).collect(Collectors.toList()));
+ }
+
+ /**
+ * Creates a new effective schema context containing the specified YANG sources. Statement parser mode is set to
+ * default mode and all YANG features are supported.
+ *
+ * @param resourcePath relative path to the directory with YANG files to be parsed
+ * @return effective schema context
+ */
+ public static EffectiveModelContext parseYangResourceDirectory(final String resourcePath) {
+ return parseYangResourceDirectory(resourcePath, YangParserConfiguration.DEFAULT);
+ }
+
+ /**
+ * Creates a new effective schema context containing the specified YANG sources. All YANG features are supported.
+ *
+ * @param resourcePath relative path to the directory with YANG files to be parsed
+ * @param parserMode mode of statement parser
+ * @return effective schema context
+ */
+ public static EffectiveModelContext parseYangResourceDirectory(final String resourcePath,
+ final YangParserConfiguration config) {
+ return parseYangResourceDirectory(resourcePath, null, config);
+ }
+
+ /**
+ * Creates a new effective schema context containing the specified YANG sources. Statement parser mode is set to
+ * default mode.
+ *
+ * @param resourcePath relative path to the directory with YANG files to be parsed
+ * @param supportedFeatures set of supported features based on which all if-feature statements in the parsed YANG
+ * models are resolved
+ * @return effective schema context
+ */
+ public static EffectiveModelContext parseYangResourceDirectory(final String resourcePath,
+ final Set<QName> supportedFeatures) {
+ return parseYangResourceDirectory(resourcePath, supportedFeatures, YangParserConfiguration.DEFAULT);
+ }
+
+ /**
+ * Creates a new effective schema context containing the specified YANG sources.
+ *
+ * @param resourcePath relative path to the directory with YANG files to be parsed
+ * @param supportedFeatures set of supported features based on which all if-feature statements in the parsed YANG
+ * models are resolved
+ * @param parserMode mode of statement parser
+ * @return effective schema context
+ */
+ @SuppressFBWarnings(value = "NP_NULL_ON_SOME_PATH_FROM_RETURN_VALUE", justification = "Wrong inferent on listFiles")
+ public static EffectiveModelContext parseYangResourceDirectory(final String resourcePath,
+ final Set<QName> supportedFeatures, final YangParserConfiguration config) {
+ final URI directoryPath;
+ try {
+ directoryPath = YangParserTestUtils.class.getResource(resourcePath).toURI();
+ } catch (URISyntaxException e) {
+ throw new IllegalArgumentException("Failed to open resource " + resourcePath, e);
+ }
+ File[] files = new File(directoryPath).listFiles(YANG_FILE_FILTER);
+ return parseYangFiles(supportedFeatures, config, Arrays.asList(files).stream().map(e->e.toPath()).collect(Collectors.toList()));
+ }
+
+ /**
+ * Creates a new effective schema context containing the specified YANG sources. Statement parser mode is set to
+ * default mode and all YANG features are supported.
+ *
+ * @param clazz Resource lookup base
+ * @param resources Resource names to be looked up
+ * @return effective schema context
+ */
+ public static EffectiveModelContext parseYangResources(final Class<?> clazz, final String... resources) {
+ return parseYangResources(clazz, Arrays.asList(resources));
+ }
+
+ public static EffectiveModelContext parseYangResources(final Class<?> clazz, final Collection<String> resources) {
+ final List<YangTextSchemaSource> sources = new ArrayList<>(resources.size());
+ for (final String r : resources) {
+ sources.add(YangTextSchemaSource.forResource(clazz, r));
+ }
+ return parseSources(YangParserConfiguration.DEFAULT, null, sources);
+ }
+
+ /**
+ * Creates a new effective schema context containing the specified YANG sources. Statement parser mode is set to
+ * default mode.
+ *
+ * @param yangDirs relative paths to the directories containing YANG files to be parsed
+ * @param yangFiles relative paths to the YANG files to be parsed
+ * @param supportedFeatures set of supported features based on which all if-feature statements in the parsed YANG
+ * models are resolved
+ * @return effective schema context
+ */
+ public static EffectiveModelContext parseYangResources(final List<String> yangDirs, final List<String> yangFiles,
+ final Set<QName> supportedFeatures) {
+ return parseYangResources(yangDirs, yangFiles, supportedFeatures, YangParserConfiguration.DEFAULT);
+ }
+
+ /**
+ * Creates a new effective schema context containing the specified YANG sources. All YANG features are supported.
+ *
+ * @param yangResourceDirs relative paths to the directories containing YANG files to be parsed
+ * @param yangResources relative paths to the YANG files to be parsed
+ * @param statementParserMode mode of statement parser
+ * @return effective schema context
+ */
+ public static EffectiveModelContext parseYangResources(final List<String> yangResourceDirs,
+ final List<String> yangResources, final YangParserConfiguration config) {
+ return parseYangResources(yangResourceDirs, yangResources, null, config);
+ }
+
+ /**
+ * Creates a new effective schema context containing the specified YANG sources.
+ *
+ * @param yangResourceDirs relative paths to the directories containing YANG files to be parsed
+ * @param yangResources relative paths to the YANG files to be parsed
+ * @param supportedFeatures set of supported features based on which all if-feature statements in the parsed YANG
+ * models are resolved
+ * @param statementParserMode mode of statement parser
+ * @return effective schema context
+ */
+ public static EffectiveModelContext parseYangResources(final List<String> yangResourceDirs,
+ final List<String> yangResources, final Set<QName> supportedFeatures,
+ final YangParserConfiguration config) {
+ final List<File> allYangFiles = new ArrayList<>();
+ for (final String yangDir : yangResourceDirs) {
+ allYangFiles.addAll(getYangFiles(yangDir));
+ }
+
+ for (final String yangFile : yangResources) {
+ try {
+ allYangFiles.add(new File(YangParserTestUtils.class.getResource(yangFile).toURI()));
+ } catch (URISyntaxException e) {
+ throw new IllegalArgumentException("Invalid resource " + yangFile, e);
+ }
+ }
+
+ return parseYangFiles(supportedFeatures, config, allYangFiles.stream().map(e->e.toPath()).collect(Collectors.toList()));
+ }
+
+ public static EffectiveModelContext parseYangSources(final YangParserConfiguration config,
+ final Set<QName> supportedFeatures, final YangTextSchemaSource... sources) {
+ return parseSources(config, supportedFeatures, Arrays.asList(sources));
+ }
+
+ public static EffectiveModelContext parseSources(final YangParserConfiguration config,
+ final Set<QName> supportedFeatures, final Collection<? extends SchemaSourceRepresentation> sources) {
+ final YangParser parser = PARSER_FACTORY.createParser(config);
+ if (supportedFeatures != null) {
+ parser.setSupportedFeatures(supportedFeatures);
+ }
+
+ try {
+ parser.addSources(sources);
+ } catch (YangSyntaxErrorException e) {
+ throw new IllegalArgumentException("Malformed source", e);
+ } catch (IOException e) {
+ throw new IllegalArgumentException("Failed to read a source", e);
+ }
+
+ try {
+ return parser.buildEffectiveModel();
+ } catch (YangParserException e) {
+ throw new IllegalStateException("Failed to assemble SchemaContext", e);
+ }
+ }
+
+ @SuppressFBWarnings(value = "NP_NULL_ON_SOME_PATH_FROM_RETURN_VALUE", justification = "Wrong inferent on listFiles")
+ private static Collection<File> getYangFiles(final String resourcePath) {
+ final URI directoryPath;
+ try {
+ directoryPath = YangParserTestUtils.class.getResource(resourcePath).toURI();
+ } catch (URISyntaxException e) {
+ throw new IllegalArgumentException("Failed to open resource directory " + resourcePath, e);
+ }
+ return Arrays.asList(new File(directoryPath).listFiles(YANG_FILE_FILTER));
+ }
+}
diff --git a/sdnr/wt/devicemanager-onap/openroadm/feature/pom.xml b/sdnr/wt/devicemanager-onap/openroadm/feature/pom.xml
index 74abefe7a..ecfdaa63c 100644
--- a/sdnr/wt/devicemanager-onap/openroadm/feature/pom.xml
+++ b/sdnr/wt/devicemanager-onap/openroadm/feature/pom.xml
@@ -20,13 +20,14 @@
~ ============LICENSE_END=======================================================
~
-->
+
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<parent>
<groupId>org.onap.ccsdk.parent</groupId>
<artifactId>single-feature-parent</artifactId>
- <version>2.4.0</version>
+ <version>2.4.1-SNAPSHOT</version>
<relativePath/>
</parent>
diff --git a/sdnr/wt/devicemanager-onap/openroadm/installer/pom.xml b/sdnr/wt/devicemanager-onap/openroadm/installer/pom.xml
index b956c1c15..ccb62033f 100755
--- a/sdnr/wt/devicemanager-onap/openroadm/installer/pom.xml
+++ b/sdnr/wt/devicemanager-onap/openroadm/installer/pom.xml
@@ -26,7 +26,7 @@
<parent>
<groupId>org.onap.ccsdk.parent</groupId>
<artifactId>odlparent-lite</artifactId>
- <version>2.4.0</version>
+ <version>2.4.1-SNAPSHOT</version>
<relativePath/>
</parent>
diff --git a/sdnr/wt/devicemanager-onap/openroadm/model/pom.xml b/sdnr/wt/devicemanager-onap/openroadm/model/pom.xml
index b6b9c1cd9..b628bfa93 100644
--- a/sdnr/wt/devicemanager-onap/openroadm/model/pom.xml
+++ b/sdnr/wt/devicemanager-onap/openroadm/model/pom.xml
@@ -20,13 +20,14 @@
~ ============LICENSE_END=======================================================
~
-->
+
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<parent>
<groupId>org.onap.ccsdk.parent</groupId>
<artifactId>binding-parent</artifactId>
- <version>2.4.0</version>
+ <version>2.4.1-SNAPSHOT</version>
<relativePath/>
</parent>
diff --git a/sdnr/wt/devicemanager-onap/openroadm/pom.xml b/sdnr/wt/devicemanager-onap/openroadm/pom.xml
index bd1d4860c..11ce28e95 100755
--- a/sdnr/wt/devicemanager-onap/openroadm/pom.xml
+++ b/sdnr/wt/devicemanager-onap/openroadm/pom.xml
@@ -20,13 +20,14 @@
~ ============LICENSE_END=======================================================
~
-->
+
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<parent>
<groupId>org.onap.ccsdk.parent</groupId>
<artifactId>odlparent-lite</artifactId>
- <version>2.4.0</version>
+ <version>2.4.1-SNAPSHOT</version>
<relativePath/>
</parent>
diff --git a/sdnr/wt/devicemanager-onap/openroadm/provider/pom.xml b/sdnr/wt/devicemanager-onap/openroadm/provider/pom.xml
index 5098575cb..0505bb06c 100644
--- a/sdnr/wt/devicemanager-onap/openroadm/provider/pom.xml
+++ b/sdnr/wt/devicemanager-onap/openroadm/provider/pom.xml
@@ -20,13 +20,14 @@
~ ============LICENSE_END=======================================================
~
-->
+
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<parent>
<groupId>org.onap.ccsdk.parent</groupId>
<artifactId>binding-parent</artifactId>
- <version>2.4.0</version>
+ <version>2.4.1-SNAPSHOT</version>
<relativePath/>
</parent>
@@ -50,26 +51,11 @@
</properties>
<dependencies>
- <!-- begin for testing -->
- <dependency>
- <groupId>org.mockito</groupId>
- <artifactId>mockito-core</artifactId>
- <version>2.28.2</version>
- <scope>test</scope>
- </dependency>
- <dependency>
- <artifactId>byte-buddy</artifactId>
- <groupId>net.bytebuddy</groupId>
- <version>1.9.10</version>
- <scope>test</scope>
- </dependency>
-
- <!-- end for testing -->
-
<dependency>
<groupId>${project.groupId}</groupId>
<artifactId>ietf-alarms</artifactId>
<version>${project.version}</version>
+ <scope>provided</scope>
</dependency>
<dependency>
<groupId>${project.groupId}</groupId>
@@ -87,7 +73,19 @@
<artifactId>sdnr-wt-data-provider-model</artifactId>
<version>${project.version}</version>
<scope>provided</scope>
- </dependency>
+ </dependency>
+ <dependency>
+ <groupId>${project.groupId}</groupId>
+ <artifactId>sdnr-wt-websocketmanager-model</artifactId>
+ <version>${project.version}</version>
+ <scope>provided</scope>
+ </dependency>
+ <dependency>
+ <groupId>${project.groupId}</groupId>
+ <artifactId>sdnr-wt-common</artifactId>
+ <version>${project.version}</version>
+ <scope>provided</scope>
+ </dependency>
<dependency>
<groupId>${project.groupId}</groupId>
<artifactId>sdnr-wt-netconfnode-state-service-model</artifactId>
@@ -104,6 +102,19 @@
<artifactId>org.osgi.core</artifactId>
<scope>provided</scope>
</dependency>
+ <!-- begin for testing -->
+ <dependency>
+ <groupId>org.mockito</groupId>
+ <artifactId>mockito-core</artifactId>
+ <version>3.2.4</version>
+ <scope>test</scope>
+ </dependency>
+ <dependency>
+ <artifactId>byte-buddy</artifactId>
+ <groupId>net.bytebuddy</groupId>
+ <scope>test</scope>
+ </dependency>
+ <!-- end for testing -->
</dependencies>
<build>
diff --git a/sdnr/wt/devicemanager-onap/openroadm/provider/src/test/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/openroadm/test/TestChangeNotificationListener.java b/sdnr/wt/devicemanager-onap/openroadm/provider/src/test/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/openroadm/test/TestChangeNotificationListener.java
index 87f195dc3..4d64cca19 100644
--- a/sdnr/wt/devicemanager-onap/openroadm/provider/src/test/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/openroadm/test/TestChangeNotificationListener.java
+++ b/sdnr/wt/devicemanager-onap/openroadm/provider/src/test/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/openroadm/test/TestChangeNotificationListener.java
@@ -32,6 +32,7 @@ import org.onap.ccsdk.features.sdnr.wt.dataprovider.model.DataProvider;
import org.onap.ccsdk.features.sdnr.wt.devicemanager.openroadm.impl.OpenroadmChangeNotificationListener;
import org.onap.ccsdk.features.sdnr.wt.netconfnodestateservice.NetconfAccessor;
import org.onap.ccsdk.features.sdnr.wt.websocketmanager.model.WebsocketManagerService;
+import org.opendaylight.yang.gen.v1.http.org.openroadm.device.rev191129.circuit.pack.features.CircuitPackComponents;
import org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.netconf.base._1._0.rev110601.EditOperationType;
import org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.netconf.notifications.rev120206.NetconfConfigChange;
import org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.netconf.notifications.rev120206.netconf.config.change.Edit;
@@ -56,7 +57,7 @@ public class TestChangeNotificationListener {
OpenroadmChangeNotificationListener notifListener =
new OpenroadmChangeNotificationListener(netconfAccessor, databaseService, notificationService);
when(netconfAccessor.getNodeId()).thenReturn(new NodeId(NODEID));
- Iterable<? extends PathArgument> pathArguments = Arrays.asList(new PathArgument() {
+ List<? extends PathArgument> pathArguments = Arrays.asList(new PathArgument() {
@Override
public int compareTo(PathArgument arg0) {
@@ -65,10 +66,10 @@ public class TestChangeNotificationListener {
@Override
public Class<? extends DataObject> getType() {
- return DataObject.class;
+ return CircuitPackComponents.class;
}
});
- InstanceIdentifier<?> target = InstanceIdentifier.create(pathArguments);
+ InstanceIdentifier<?> target = InstanceIdentifier.unsafeOf(pathArguments);
notifListener.onNetconfConfigChange(createNotification(EditOperationType.Create, target));
EventlogEntity event = new EventlogBuilder().setNodeId(NODEID)
diff --git a/sdnr/wt/devicemanager-onap/openroadm/provider/src/test/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/openroadm/test/TestOpenRoadmDeviceChangeNotification.java b/sdnr/wt/devicemanager-onap/openroadm/provider/src/test/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/openroadm/test/TestOpenRoadmDeviceChangeNotification.java
index ca9ce351c..2e94e79ef 100644
--- a/sdnr/wt/devicemanager-onap/openroadm/provider/src/test/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/openroadm/test/TestOpenRoadmDeviceChangeNotification.java
+++ b/sdnr/wt/devicemanager-onap/openroadm/provider/src/test/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/openroadm/test/TestOpenRoadmDeviceChangeNotification.java
@@ -41,6 +41,7 @@ import org.opendaylight.yang.gen.v1.http.org.openroadm.device.rev191129.CreateTe
import org.opendaylight.yang.gen.v1.http.org.openroadm.device.rev191129.CreateTechInfoNotificationBuilder;
import org.opendaylight.yang.gen.v1.http.org.openroadm.device.rev191129.change.notification.Edit;
import org.opendaylight.yang.gen.v1.http.org.openroadm.device.rev191129.change.notification.EditBuilder;
+import org.opendaylight.yang.gen.v1.http.org.openroadm.device.rev191129.circuit.pack.features.circuit.pack.components.Component;
import org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.netconf.base._1._0.rev110601.EditOperationType;
import org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.data.provider.rev201110.EventlogBuilder;
import org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.data.provider.rev201110.EventlogEntity;
@@ -65,7 +66,7 @@ public class TestOpenRoadmDeviceChangeNotification {
public void testOnChangeNotification() {
when(netconfAccessor.getNodeId()).thenReturn(new NodeId(NODEID));
- Iterable<? extends PathArgument> pathArguments = Arrays.asList(new PathArgument() {
+ List<? extends PathArgument> pathArguments = Arrays.asList(new PathArgument() {
@Override
public int compareTo(PathArgument arg0) {
@@ -74,10 +75,10 @@ public class TestOpenRoadmDeviceChangeNotification {
@Override
public Class<? extends DataObject> getType() {
- return DataObject.class;
+ return Component.class;
}
});
- InstanceIdentifier<?> target = InstanceIdentifier.create(pathArguments);
+ InstanceIdentifier<?> target = InstanceIdentifier.unsafeOf(pathArguments);
deviceChangeListener.onChangeNotification(createNotification(EditOperationType.Create, target));
EventlogEntity event =
diff --git a/sdnr/wt/devicemanager-onap/openroadm/provider/src/test/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/openroadm/test/TestOpenRoadmPMDataBuilder.java b/sdnr/wt/devicemanager-onap/openroadm/provider/src/test/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/openroadm/test/TestOpenRoadmPMDataBuilder.java
index 2a70ec7b6..202449033 100644
--- a/sdnr/wt/devicemanager-onap/openroadm/provider/src/test/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/openroadm/test/TestOpenRoadmPMDataBuilder.java
+++ b/sdnr/wt/devicemanager-onap/openroadm/provider/src/test/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/openroadm/test/TestOpenRoadmPMDataBuilder.java
@@ -40,6 +40,7 @@ import org.opendaylight.mdsal.binding.api.DataBroker;
import org.opendaylight.mdsal.common.api.LogicalDatastoreType;
import org.opendaylight.yang.gen.v1.http.org.openroadm.common.alarm.pm.types.rev191129.Direction;
import org.opendaylight.yang.gen.v1.http.org.openroadm.common.alarm.pm.types.rev191129.Location;
+import org.opendaylight.yang.gen.v1.http.org.openroadm.device.rev191129.circuit.pack.features.circuit.pack.components.Component;
import org.opendaylight.yang.gen.v1.http.org.openroadm.pm.rev191129.HistoricalPmList;
import org.opendaylight.yang.gen.v1.http.org.openroadm.pm.rev191129.historical.pm.group.HistoricalPm;
import org.opendaylight.yang.gen.v1.http.org.openroadm.pm.rev191129.historical.pm.group.HistoricalPmBuilder;
@@ -142,10 +143,10 @@ public class TestOpenRoadmPMDataBuilder {
@Override
public @NonNull Class<? extends DataObject> getType() {
// TODO Auto-generated method stub
- return Pmdata15mEntity.class;
+ return Component.class;
}
};
- historicalPmEntryBuiler.setPmResourceInstance(InstanceIdentifier.create(Arrays.asList(pa)))
+ historicalPmEntryBuiler.setPmResourceInstance(InstanceIdentifier.unsafeOf(Arrays.asList(pa)))
.setPmResourceTypeExtension("dshjdekjdewkk")
.setPmResourceType(ResourceTypeEnum.CircuitPack).setHistoricalPm(historicalPMCollection);
@@ -179,11 +180,11 @@ public class TestOpenRoadmPMDataBuilder {
@Override
public Class<? extends DataObject> getType() {
// TODO Auto-generated method stub
- return Pmdata15mEntity.class;
+ return Component.class;
}
};
historicalPMCollection.put(historicalPmBuilder.key(), historicalPmBuilder.build());
- historicalPmEntryBuiler.setPmResourceInstance(InstanceIdentifier.create(Arrays.asList(pa)))
+ historicalPmEntryBuiler.setPmResourceInstance(InstanceIdentifier.unsafeOf(Arrays.asList(pa)))
.setPmResourceTypeExtension("dshjdekjdewkk")
.setPmResourceType(ResourceTypeEnum.Device).setHistoricalPm(historicalPMCollection);
diff --git a/sdnr/wt/devicemanager-onap/openroadm71/feature/pom.xml b/sdnr/wt/devicemanager-onap/openroadm71/feature/pom.xml
index e8603fac8..b74d9e1b2 100644
--- a/sdnr/wt/devicemanager-onap/openroadm71/feature/pom.xml
+++ b/sdnr/wt/devicemanager-onap/openroadm71/feature/pom.xml
@@ -20,13 +20,14 @@
~ ============LICENSE_END=======================================================
~
-->
+
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<parent>
<groupId>org.onap.ccsdk.parent</groupId>
<artifactId>single-feature-parent</artifactId>
- <version>2.4.0</version>
+ <version>2.4.1-SNAPSHOT</version>
<relativePath/>
</parent>
diff --git a/sdnr/wt/devicemanager-onap/openroadm71/installer/pom.xml b/sdnr/wt/devicemanager-onap/openroadm71/installer/pom.xml
index 45f41a0df..c1aa2ac65 100755
--- a/sdnr/wt/devicemanager-onap/openroadm71/installer/pom.xml
+++ b/sdnr/wt/devicemanager-onap/openroadm71/installer/pom.xml
@@ -26,7 +26,7 @@
<parent>
<groupId>org.onap.ccsdk.parent</groupId>
<artifactId>odlparent-lite</artifactId>
- <version>2.4.0</version>
+ <version>2.4.1-SNAPSHOT</version>
<relativePath/>
</parent>
diff --git a/sdnr/wt/devicemanager-onap/openroadm71/model/pom.xml b/sdnr/wt/devicemanager-onap/openroadm71/model/pom.xml
index 264b224af..b5e6933ea 100644
--- a/sdnr/wt/devicemanager-onap/openroadm71/model/pom.xml
+++ b/sdnr/wt/devicemanager-onap/openroadm71/model/pom.xml
@@ -20,13 +20,14 @@
~ ============LICENSE_END=======================================================
~
-->
+
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<parent>
<groupId>org.onap.ccsdk.parent</groupId>
<artifactId>binding-parent</artifactId>
- <version>2.4.0</version>
+ <version>2.4.1-SNAPSHOT</version>
<relativePath/>
</parent>
diff --git a/sdnr/wt/devicemanager-onap/openroadm71/pom.xml b/sdnr/wt/devicemanager-onap/openroadm71/pom.xml
index 93814a098..7dc7a5f54 100755
--- a/sdnr/wt/devicemanager-onap/openroadm71/pom.xml
+++ b/sdnr/wt/devicemanager-onap/openroadm71/pom.xml
@@ -20,13 +20,14 @@
~ ============LICENSE_END=======================================================
~
-->
+
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<parent>
<groupId>org.onap.ccsdk.parent</groupId>
<artifactId>odlparent-lite</artifactId>
- <version>2.4.0</version>
+ <version>2.4.1-SNAPSHOT</version>
<relativePath/>
</parent>
diff --git a/sdnr/wt/devicemanager-onap/openroadm71/provider/pom.xml b/sdnr/wt/devicemanager-onap/openroadm71/provider/pom.xml
index 40d1b6e2c..2d94bc2c7 100644
--- a/sdnr/wt/devicemanager-onap/openroadm71/provider/pom.xml
+++ b/sdnr/wt/devicemanager-onap/openroadm71/provider/pom.xml
@@ -20,13 +20,14 @@
~ ============LICENSE_END=======================================================
~
-->
+
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<parent>
<groupId>org.onap.ccsdk.parent</groupId>
<artifactId>binding-parent</artifactId>
- <version>2.4.0</version>
+ <version>2.4.1-SNAPSHOT</version>
<relativePath/>
</parent>
@@ -50,21 +51,6 @@
</properties>
<dependencies>
- <!-- begin for testing -->
- <dependency>
- <groupId>org.mockito</groupId>
- <artifactId>mockito-core</artifactId>
-<!-- <version>2.28.2</version> -->
- <scope>test</scope>
- </dependency>
- <dependency>
- <artifactId>byte-buddy</artifactId>
- <groupId>net.bytebuddy</groupId>
-<!-- <version>1.9.10</version> -->
- <scope>test</scope>
- </dependency>
-
- <!-- end for testing -->
<dependency>
<groupId>${project.groupId}</groupId>
@@ -91,6 +77,18 @@
</dependency>
<dependency>
<groupId>${project.groupId}</groupId>
+ <artifactId>sdnr-wt-common</artifactId>
+ <version>${project.version}</version>
+ <scope>provided</scope>
+ </dependency>
+ <dependency>
+ <groupId>${project.groupId}</groupId>
+ <artifactId>sdnr-wt-websocketmanager-model</artifactId>
+ <version>${project.version}</version>
+ <scope>provided</scope>
+ </dependency>
+ <dependency>
+ <groupId>${project.groupId}</groupId>
<artifactId>sdnr-wt-netconfnode-state-service-model</artifactId>
<version>${project.version}</version>
<scope>provided</scope>
@@ -105,6 +103,18 @@
<artifactId>org.osgi.core</artifactId>
<scope>provided</scope>
</dependency>
+ <!-- begin for testing -->
+ <dependency>
+ <groupId>org.mockito</groupId>
+ <artifactId>mockito-core</artifactId>
+ <scope>test</scope>
+ </dependency>
+ <dependency>
+ <artifactId>byte-buddy</artifactId>
+ <groupId>net.bytebuddy</groupId>
+ <scope>test</scope>
+ </dependency>
+ <!-- end for testing -->
</dependencies>
<build>
diff --git a/sdnr/wt/devicemanager-onap/openroadm71/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/openroadm71/impl/OpenroadmInventoryInput.java b/sdnr/wt/devicemanager-onap/openroadm71/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/openroadm71/impl/OpenroadmInventoryInput.java
index 1f6cfd658..2f48d79f7 100644
--- a/sdnr/wt/devicemanager-onap/openroadm71/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/openroadm71/impl/OpenroadmInventoryInput.java
+++ b/sdnr/wt/devicemanager-onap/openroadm71/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/openroadm71/impl/OpenroadmInventoryInput.java
@@ -22,11 +22,11 @@
package org.onap.ccsdk.features.sdnr.wt.devicemanager.openroadm71.impl;
import org.onap.ccsdk.features.sdnr.wt.netconfnodestateservice.NetconfAccessor;
+import org.opendaylight.yang.gen.v1.http.org.openroadm.device.rev200529.OrgOpenroadmDevice;
import org.opendaylight.yang.gen.v1.http.org.openroadm.device.rev200529.circuit.packs.CircuitPacks;
import org.opendaylight.yang.gen.v1.http.org.openroadm.device.rev200529.interfaces.grp.Interface;
-import org.opendaylight.yang.gen.v1.http.org.openroadm.device.rev200529.org.openroadm.device.container.OrgOpenroadmDevice;
-import org.opendaylight.yang.gen.v1.http.org.openroadm.device.rev200529.org.openroadm.device.container.org.openroadm.device.Info;
-import org.opendaylight.yang.gen.v1.http.org.openroadm.device.rev200529.org.openroadm.device.container.org.openroadm.device.Xponder;
+import org.opendaylight.yang.gen.v1.http.org.openroadm.device.rev200529.org.openroadm.device.Info;
+import org.opendaylight.yang.gen.v1.http.org.openroadm.device.rev200529.org.openroadm.device.Xponder;
import org.opendaylight.yang.gen.v1.http.org.openroadm.device.rev200529.shelves.Shelves;
import org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.data.provider.rev201110.Inventory;
import org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.data.provider.rev201110.InventoryBuilder;
diff --git a/sdnr/wt/devicemanager-onap/openroadm71/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/openroadm71/impl/OpenroadmNetworkElement.java b/sdnr/wt/devicemanager-onap/openroadm71/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/openroadm71/impl/OpenroadmNetworkElement.java
index 180091718..2a22e1e9d 100644
--- a/sdnr/wt/devicemanager-onap/openroadm71/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/openroadm71/impl/OpenroadmNetworkElement.java
+++ b/sdnr/wt/devicemanager-onap/openroadm71/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/openroadm71/impl/OpenroadmNetworkElement.java
@@ -33,10 +33,10 @@ import org.onap.ccsdk.features.sdnr.wt.devicemanager.service.DeviceManagerServic
import org.onap.ccsdk.features.sdnr.wt.netconfnodestateservice.NetconfAccessor;
import org.onap.ccsdk.features.sdnr.wt.netconfnodestateservice.NetconfBindingAccessor;
import org.opendaylight.mdsal.common.api.LogicalDatastoreType;
+import org.opendaylight.yang.gen.v1.http.org.openroadm.device.rev200529.OrgOpenroadmDevice;
import org.opendaylight.yang.gen.v1.http.org.openroadm.device.rev200529.circuit.packs.CircuitPacks;
import org.opendaylight.yang.gen.v1.http.org.openroadm.device.rev200529.interfaces.grp.Interface;
-import org.opendaylight.yang.gen.v1.http.org.openroadm.device.rev200529.org.openroadm.device.container.OrgOpenroadmDevice;
-import org.opendaylight.yang.gen.v1.http.org.openroadm.device.rev200529.org.openroadm.device.container.org.openroadm.device.Xponder;
+import org.opendaylight.yang.gen.v1.http.org.openroadm.device.rev200529.org.openroadm.device.Xponder;
import org.opendaylight.yang.gen.v1.http.org.openroadm.device.rev200529.shelf.Slots;
import org.opendaylight.yang.gen.v1.http.org.openroadm.device.rev200529.shelves.Shelves;
import org.opendaylight.yang.gen.v1.http.org.openroadm.device.rev200529.xponder.XpdrPort;
@@ -310,7 +310,8 @@ public class OpenroadmNetworkElement extends OpenroadmNetworkElementBase {
}
private OrgOpenroadmDevice readDevice(NetconfBindingAccessor accessor) {
- InstanceIdentifier<OrgOpenroadmDevice> deviceId = InstanceIdentifier.create(OrgOpenroadmDevice.class);
+ final Class<OrgOpenroadmDevice> openRoadmDev = OrgOpenroadmDevice.class;
+ InstanceIdentifier<OrgOpenroadmDevice> deviceId = InstanceIdentifier.builder(openRoadmDev).build();
return accessor.getTransactionUtils().readData(accessor.getDataBroker(), LogicalDatastoreType.OPERATIONAL,
deviceId);
}
diff --git a/sdnr/wt/devicemanager-onap/openroadm71/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/openroadm71/impl/OpenroadmNetworkElementFactory.java b/sdnr/wt/devicemanager-onap/openroadm71/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/openroadm71/impl/OpenroadmNetworkElementFactory.java
index 552058fd8..04b6b2ae1 100644
--- a/sdnr/wt/devicemanager-onap/openroadm71/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/openroadm71/impl/OpenroadmNetworkElementFactory.java
+++ b/sdnr/wt/devicemanager-onap/openroadm71/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/openroadm71/impl/OpenroadmNetworkElementFactory.java
@@ -28,7 +28,7 @@ import org.onap.ccsdk.features.sdnr.wt.devicemanager.ne.service.NetworkElement;
import org.onap.ccsdk.features.sdnr.wt.devicemanager.service.DeviceManagerServiceProvider;
import org.onap.ccsdk.features.sdnr.wt.netconfnodestateservice.NetconfAccessor;
import org.onap.ccsdk.features.sdnr.wt.netconfnodestateservice.NetconfBindingAccessor;
-import org.opendaylight.yang.gen.v1.http.org.openroadm.device.rev200529.org.openroadm.device.container.OrgOpenroadmDevice;
+import org.opendaylight.yang.gen.v1.http.org.openroadm.device.rev200529.OrgOpenroadmDevice;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
diff --git a/sdnr/wt/devicemanager-onap/openroadm71/provider/src/main/yang/org-openroadm-device.yang b/sdnr/wt/devicemanager-onap/openroadm71/provider/src/main/yang/org-openroadm-device.yang
index 5e690f5a5..281e94bdb 100644
--- a/sdnr/wt/devicemanager-onap/openroadm71/provider/src/main/yang/org-openroadm-device.yang
+++ b/sdnr/wt/devicemanager-onap/openroadm71/provider/src/main/yang/org-openroadm-device.yang
@@ -1851,7 +1851,7 @@ module org-openroadm-device {
"Mux group grouping";
}
- grouping org-openroadm-device-container {
+ // grouping org-openroadm-device-container {
container org-openroadm-device {
container info {
uses device-common;
@@ -2286,7 +2286,7 @@ module org-openroadm-device {
uses mux-grp;
}
}
- }
+ // }
grouping common-session-parms {
description
@@ -2604,5 +2604,5 @@ module org-openroadm-device {
}
}
- uses org-openroadm-device-container;
+ //uses org-openroadm-device-container;
}
diff --git a/sdnr/wt/devicemanager-onap/openroadm71/provider/src/test/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/openroadm71/test/TestChangeNotificationListener.java b/sdnr/wt/devicemanager-onap/openroadm71/provider/src/test/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/openroadm71/test/TestChangeNotificationListener.java
index f7732c7af..fa21e77fe 100644
--- a/sdnr/wt/devicemanager-onap/openroadm71/provider/src/test/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/openroadm71/test/TestChangeNotificationListener.java
+++ b/sdnr/wt/devicemanager-onap/openroadm71/provider/src/test/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/openroadm71/test/TestChangeNotificationListener.java
@@ -32,6 +32,7 @@ import org.onap.ccsdk.features.sdnr.wt.dataprovider.model.DataProvider;
import org.onap.ccsdk.features.sdnr.wt.devicemanager.openroadm71.impl.OpenroadmChangeNotificationListener;
import org.onap.ccsdk.features.sdnr.wt.netconfnodestateservice.NetconfAccessor;
import org.onap.ccsdk.features.sdnr.wt.websocketmanager.model.WebsocketManagerService;
+import org.opendaylight.yang.gen.v1.http.org.openroadm.device.rev200529.circuit.pack.features.circuit.pack.components.Component;
import org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.netconf.base._1._0.rev110601.EditOperationType;
import org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.netconf.notifications.rev120206.NetconfConfigChange;
import org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.netconf.notifications.rev120206.netconf.config.change.Edit;
@@ -56,7 +57,7 @@ public class TestChangeNotificationListener {
OpenroadmChangeNotificationListener notifListener =
new OpenroadmChangeNotificationListener(netconfAccessor, databaseService, notificationService);
when(netconfAccessor.getNodeId()).thenReturn(new NodeId(NODEID));
- Iterable<? extends PathArgument> pathArguments = Arrays.asList(new PathArgument() {
+ List<? extends PathArgument> pathArguments = Arrays.asList(new PathArgument() {
@Override
public int compareTo(PathArgument arg0) {
@@ -65,10 +66,10 @@ public class TestChangeNotificationListener {
@Override
public Class<? extends DataObject> getType() {
- return DataObject.class;
+ return Component.class;
}
});
- InstanceIdentifier<?> target = InstanceIdentifier.create(pathArguments);
+ InstanceIdentifier<?> target = InstanceIdentifier.unsafeOf(pathArguments);
notifListener.onNetconfConfigChange(createNotification(EditOperationType.Create, target));
EventlogEntity event = new EventlogBuilder().setNodeId(NODEID)
diff --git a/sdnr/wt/devicemanager-onap/openroadm71/provider/src/test/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/openroadm71/test/TestOpenRoadmDeviceChangeNotification.java b/sdnr/wt/devicemanager-onap/openroadm71/provider/src/test/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/openroadm71/test/TestOpenRoadmDeviceChangeNotification.java
index 6188cc5e6..f9b5b514d 100644
--- a/sdnr/wt/devicemanager-onap/openroadm71/provider/src/test/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/openroadm71/test/TestOpenRoadmDeviceChangeNotification.java
+++ b/sdnr/wt/devicemanager-onap/openroadm71/provider/src/test/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/openroadm71/test/TestOpenRoadmDeviceChangeNotification.java
@@ -41,6 +41,7 @@ import org.opendaylight.yang.gen.v1.http.org.openroadm.device.rev200529.CreateTe
import org.opendaylight.yang.gen.v1.http.org.openroadm.device.rev200529.CreateTechInfoNotificationBuilder;
import org.opendaylight.yang.gen.v1.http.org.openroadm.device.rev200529.change.notification.Edit;
import org.opendaylight.yang.gen.v1.http.org.openroadm.device.rev200529.change.notification.EditBuilder;
+import org.opendaylight.yang.gen.v1.http.org.openroadm.device.rev200529.circuit.pack.features.circuit.pack.components.Component;
import org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.netconf.base._1._0.rev110601.EditOperationType;
import org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.data.provider.rev201110.EventlogBuilder;
import org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.data.provider.rev201110.EventlogEntity;
@@ -65,7 +66,7 @@ public class TestOpenRoadmDeviceChangeNotification {
public void testOnChangeNotification() {
when(netconfAccessor.getNodeId()).thenReturn(new NodeId(NODEID));
- Iterable<? extends PathArgument> pathArguments = Arrays.asList(new PathArgument() {
+ List<? extends PathArgument> pathArguments = Arrays.asList(new PathArgument() {
@Override
public int compareTo(PathArgument arg0) {
@@ -74,10 +75,10 @@ public class TestOpenRoadmDeviceChangeNotification {
@Override
public Class<? extends DataObject> getType() {
- return DataObject.class;
+ return Component.class;
}
});
- InstanceIdentifier<?> target = InstanceIdentifier.create(pathArguments);
+ InstanceIdentifier<?> target = InstanceIdentifier.unsafeOf(pathArguments);
deviceChangeListener.onChangeNotification(createNotification(EditOperationType.Create, target));
EventlogEntity event =
diff --git a/sdnr/wt/devicemanager-onap/openroadm71/provider/src/test/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/openroadm71/test/TestOpenRoadmInventory.java b/sdnr/wt/devicemanager-onap/openroadm71/provider/src/test/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/openroadm71/test/TestOpenRoadmInventory.java
index 2b2b2c618..7a03aa385 100644
--- a/sdnr/wt/devicemanager-onap/openroadm71/provider/src/test/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/openroadm71/test/TestOpenRoadmInventory.java
+++ b/sdnr/wt/devicemanager-onap/openroadm71/provider/src/test/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/openroadm71/test/TestOpenRoadmInventory.java
@@ -32,12 +32,12 @@ import org.opendaylight.yang.gen.v1.http.org.openroadm.common.node.types.rev1911
import org.opendaylight.yang.gen.v1.http.org.openroadm.common.state.types.rev191129.LifecycleState;
import org.opendaylight.yang.gen.v1.http.org.openroadm.common.state.types.rev191129.State;
import org.opendaylight.yang.gen.v1.http.org.openroadm.common.types.rev200529.OpenroadmVersionType;
+import org.opendaylight.yang.gen.v1.http.org.openroadm.device.rev200529.OrgOpenroadmDevice;
import org.opendaylight.yang.gen.v1.http.org.openroadm.device.rev200529.circuit.packs.CircuitPacks;
import org.opendaylight.yang.gen.v1.http.org.openroadm.device.rev200529.interfaces.grp.Interface;
-import org.opendaylight.yang.gen.v1.http.org.openroadm.device.rev200529.org.openroadm.device.container.OrgOpenroadmDevice;
-import org.opendaylight.yang.gen.v1.http.org.openroadm.device.rev200529.org.openroadm.device.container.org.openroadm.device.Info;
-import org.opendaylight.yang.gen.v1.http.org.openroadm.device.rev200529.org.openroadm.device.container.org.openroadm.device.InfoBuilder;
-import org.opendaylight.yang.gen.v1.http.org.openroadm.device.rev200529.org.openroadm.device.container.org.openroadm.device.Xponder;
+import org.opendaylight.yang.gen.v1.http.org.openroadm.device.rev200529.org.openroadm.device.Info;
+import org.opendaylight.yang.gen.v1.http.org.openroadm.device.rev200529.org.openroadm.device.InfoBuilder;
+import org.opendaylight.yang.gen.v1.http.org.openroadm.device.rev200529.org.openroadm.device.Xponder;
import org.opendaylight.yang.gen.v1.http.org.openroadm.device.rev200529.shelves.Shelves;
import org.opendaylight.yang.gen.v1.http.org.openroadm.device.types.rev191129.NodeTypes;
import org.opendaylight.yang.gen.v1.http.org.openroadm.device.types.rev191129.XpdrNodeTypes;
diff --git a/sdnr/wt/devicemanager-onap/openroadm71/provider/src/test/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/openroadm71/test/TestOpenRoadmNetworkElement.java b/sdnr/wt/devicemanager-onap/openroadm71/provider/src/test/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/openroadm71/test/TestOpenRoadmNetworkElement.java
index 9ef0f6474..a018df739 100644
--- a/sdnr/wt/devicemanager-onap/openroadm71/provider/src/test/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/openroadm71/test/TestOpenRoadmNetworkElement.java
+++ b/sdnr/wt/devicemanager-onap/openroadm71/provider/src/test/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/openroadm71/test/TestOpenRoadmNetworkElement.java
@@ -50,16 +50,16 @@ import org.opendaylight.yang.gen.v1.http.org.openroadm.common.node.types.rev1911
import org.opendaylight.yang.gen.v1.http.org.openroadm.common.state.types.rev191129.LifecycleState;
import org.opendaylight.yang.gen.v1.http.org.openroadm.common.state.types.rev191129.State;
import org.opendaylight.yang.gen.v1.http.org.openroadm.common.types.rev200529.OpenroadmVersionType;
+import org.opendaylight.yang.gen.v1.http.org.openroadm.device.rev200529.OrgOpenroadmDevice;
import org.opendaylight.yang.gen.v1.http.org.openroadm.device.rev200529.circuit.pack.ParentCircuitPack;
import org.opendaylight.yang.gen.v1.http.org.openroadm.device.rev200529.circuit.packs.CircuitPacks;
import org.opendaylight.yang.gen.v1.http.org.openroadm.device.rev200529.circuit.packs.CircuitPacksKey;
import org.opendaylight.yang.gen.v1.http.org.openroadm.device.rev200529.interfaces.grp.Interface;
import org.opendaylight.yang.gen.v1.http.org.openroadm.device.rev200529.interfaces.grp.InterfaceKey;
-import org.opendaylight.yang.gen.v1.http.org.openroadm.device.rev200529.org.openroadm.device.container.OrgOpenroadmDevice;
-import org.opendaylight.yang.gen.v1.http.org.openroadm.device.rev200529.org.openroadm.device.container.org.openroadm.device.Info;
-import org.opendaylight.yang.gen.v1.http.org.openroadm.device.rev200529.org.openroadm.device.container.org.openroadm.device.InfoBuilder;
-import org.opendaylight.yang.gen.v1.http.org.openroadm.device.rev200529.org.openroadm.device.container.org.openroadm.device.Xponder;
-import org.opendaylight.yang.gen.v1.http.org.openroadm.device.rev200529.org.openroadm.device.container.org.openroadm.device.XponderKey;
+import org.opendaylight.yang.gen.v1.http.org.openroadm.device.rev200529.org.openroadm.device.Info;
+import org.opendaylight.yang.gen.v1.http.org.openroadm.device.rev200529.org.openroadm.device.InfoBuilder;
+import org.opendaylight.yang.gen.v1.http.org.openroadm.device.rev200529.org.openroadm.device.Xponder;
+import org.opendaylight.yang.gen.v1.http.org.openroadm.device.rev200529.org.openroadm.device.XponderKey;
import org.opendaylight.yang.gen.v1.http.org.openroadm.device.rev200529.shelf.Slots;
import org.opendaylight.yang.gen.v1.http.org.openroadm.device.rev200529.shelf.SlotsKey;
import org.opendaylight.yang.gen.v1.http.org.openroadm.device.rev200529.shelves.Shelves;
diff --git a/sdnr/wt/devicemanager-onap/openroadm71/provider/src/test/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/openroadm71/test/TestOpenRoadmNetworkElementFactory.java b/sdnr/wt/devicemanager-onap/openroadm71/provider/src/test/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/openroadm71/test/TestOpenRoadmNetworkElementFactory.java
index a35c5f0ae..5e71fac44 100644
--- a/sdnr/wt/devicemanager-onap/openroadm71/provider/src/test/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/openroadm71/test/TestOpenRoadmNetworkElementFactory.java
+++ b/sdnr/wt/devicemanager-onap/openroadm71/provider/src/test/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/openroadm71/test/TestOpenRoadmNetworkElementFactory.java
@@ -37,7 +37,7 @@ import org.onap.ccsdk.features.sdnr.wt.netconfnodestateservice.NetconfBindingAcc
import org.onap.ccsdk.features.sdnr.wt.netconfnodestateservice.TransactionUtils;
import org.opendaylight.mdsal.binding.api.DataBroker;
import org.opendaylight.mdsal.common.api.LogicalDatastoreType;
-import org.opendaylight.yang.gen.v1.http.org.openroadm.device.rev200529.org.openroadm.device.container.OrgOpenroadmDevice;
+import org.opendaylight.yang.gen.v1.http.org.openroadm.device.rev200529.OrgOpenroadmDevice;
import org.opendaylight.yang.gen.v1.urn.tbd.params.xml.ns.yang.network.topology.rev131021.NodeId;
import org.opendaylight.yangtools.yang.binding.InstanceIdentifier;
diff --git a/sdnr/wt/devicemanager-onap/openroadm71/provider/src/test/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/openroadm71/test/TestOpenRoadmPMDataBuilder.java b/sdnr/wt/devicemanager-onap/openroadm71/provider/src/test/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/openroadm71/test/TestOpenRoadmPMDataBuilder.java
index 3a0781e8f..49585acb2 100644
--- a/sdnr/wt/devicemanager-onap/openroadm71/provider/src/test/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/openroadm71/test/TestOpenRoadmPMDataBuilder.java
+++ b/sdnr/wt/devicemanager-onap/openroadm71/provider/src/test/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/openroadm71/test/TestOpenRoadmPMDataBuilder.java
@@ -40,6 +40,7 @@ import org.opendaylight.mdsal.binding.api.DataBroker;
import org.opendaylight.mdsal.common.api.LogicalDatastoreType;
import org.opendaylight.yang.gen.v1.http.org.openroadm.common.alarm.pm.types.rev191129.Direction;
import org.opendaylight.yang.gen.v1.http.org.openroadm.common.alarm.pm.types.rev191129.Location;
+import org.opendaylight.yang.gen.v1.http.org.openroadm.device.rev200529.circuit.pack.features.circuit.pack.components.Component;
import org.opendaylight.yang.gen.v1.http.org.openroadm.pm.rev200529.HistoricalPmList;
import org.opendaylight.yang.gen.v1.http.org.openroadm.pm.rev200529.historical.pm.group.HistoricalPm;
import org.opendaylight.yang.gen.v1.http.org.openroadm.pm.rev200529.historical.pm.group.HistoricalPmBuilder;
@@ -142,10 +143,10 @@ public class TestOpenRoadmPMDataBuilder {
@Override
public @NonNull Class<? extends DataObject> getType() {
// TODO Auto-generated method stub
- return Pmdata15mEntity.class;
+ return Component.class;
}
};
- historicalPmEntryBuiler.setPmResourceInstance(InstanceIdentifier.create(Arrays.asList(pa)))
+ historicalPmEntryBuiler.setPmResourceInstance(InstanceIdentifier.unsafeOf(Arrays.asList(pa)))
.setPmResourceTypeExtension("dshjdekjdewkk")
.setPmResourceType(ResourceTypeEnum.CircuitPack).setHistoricalPm(historicalPMCollection);
@@ -179,11 +180,11 @@ public class TestOpenRoadmPMDataBuilder {
@Override
public Class<? extends DataObject> getType() {
// TODO Auto-generated method stub
- return Pmdata15mEntity.class;
+ return Component.class;
}
};
historicalPMCollection.put(historicalPmBuilder.key(), historicalPmBuilder.build());
- historicalPmEntryBuiler.setPmResourceInstance(InstanceIdentifier.create(Arrays.asList(pa)))
+ historicalPmEntryBuiler.setPmResourceInstance(InstanceIdentifier.unsafeOf(Arrays.asList(pa)))
.setPmResourceTypeExtension("dshjdekjdewkk")
.setPmResourceType(ResourceTypeEnum.Device).setHistoricalPm(historicalPMCollection);