aboutsummaryrefslogtreecommitdiffstats
path: root/sdnr/wt/devicemanager-onf14/provider/src/main/java
diff options
context:
space:
mode:
authoralexs <alexandru.stancu@highstreet-technologies.com>2020-08-21 15:01:24 +0300
committeralex.stancu <alexandru.stancu@highstreet-technologies.com>2020-08-24 11:46:01 +0300
commit926eb80c2c053d4d333875d3d4245288b3cd9f75 (patch)
tree105b8fdc9f1d1486fe14c3dab2a310663b4adddf /sdnr/wt/devicemanager-onf14/provider/src/main/java
parent97cc01117ee7da2e43d9a6ba2892aada5de18f47 (diff)
Initial commit for device manager 1.4
Add device manager support for ONF Core Model 1.4 Issue-ID: CCSDK-2579 Change-Id: I0b0f27554dc33de08019ec50ac61fa3fd5367068 Signed-off-by: alexs <alexandru.stancu@highstreet-technologies.com> Signed-off-by: alex.stancu <alexandru.stancu@highstreet-technologies.com>
Diffstat (limited to 'sdnr/wt/devicemanager-onf14/provider/src/main/java')
-rw-r--r--sdnr/wt/devicemanager-onf14/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/onf14/impl/DeviceManagerOnf14Impl.java89
-rw-r--r--sdnr/wt/devicemanager-onf14/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/onf14/impl/Onf14AirInterfaceNotificationListener.java78
-rw-r--r--sdnr/wt/devicemanager-onf14/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/onf14/impl/Onf14NetworkElement.java382
-rw-r--r--sdnr/wt/devicemanager-onf14/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/onf14/impl/Onf14NetworkElementFactory.java43
-rw-r--r--sdnr/wt/devicemanager-onf14/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/onf14/impl/Onf14ToInternalDataModel.java128
-rw-r--r--sdnr/wt/devicemanager-onf14/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/onf14/yang/Control.java26
-rw-r--r--sdnr/wt/devicemanager-onf14/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/onf14/yang/OperatorState.java22
-rw-r--r--sdnr/wt/devicemanager-onf14/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/onf14/yang/Resource.java22
-rw-r--r--sdnr/wt/devicemanager-onf14/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/onf14/yang/ResourceMatch.java22
-rw-r--r--sdnr/wt/devicemanager-onf14/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/onf14/yang/SeverityWithClear.java22
-rw-r--r--sdnr/wt/devicemanager-onf14/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/onf14/yang/package-info.java18
-rw-r--r--sdnr/wt/devicemanager-onf14/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/ietf/params/xml/ns/yang/ietf/alarms/rev190911/OperatorStateBuilder.java26
-rw-r--r--sdnr/wt/devicemanager-onf14/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/ietf/params/xml/ns/yang/ietf/alarms/rev190911/ResourceBuilder.java26
-rw-r--r--sdnr/wt/devicemanager-onf14/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/ietf/params/xml/ns/yang/ietf/alarms/rev190911/ResourceMatchBuilder.java26
-rw-r--r--sdnr/wt/devicemanager-onf14/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/ietf/params/xml/ns/yang/ietf/alarms/rev190911/SeverityWithClearBuilder.java26
-rw-r--r--sdnr/wt/devicemanager-onf14/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/ietf/params/xml/ns/yang/ietf/alarms/rev190911/alarms/ControlMaxAlarmStatusChangesBuilder.java26
16 files changed, 982 insertions, 0 deletions
diff --git a/sdnr/wt/devicemanager-onf14/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/onf14/impl/DeviceManagerOnf14Impl.java b/sdnr/wt/devicemanager-onf14/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/onf14/impl/DeviceManagerOnf14Impl.java
new file mode 100644
index 000000000..df34ce5c8
--- /dev/null
+++ b/sdnr/wt/devicemanager-onf14/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/onf14/impl/DeviceManagerOnf14Impl.java
@@ -0,0 +1,89 @@
+/*
+ * ============LICENSE_START========================================================================
+ * ONAP : ccsdk feature sdnr wt
+ * =================================================================================================
+ * Copyright (C) 2020 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.impl;
+
+import org.onap.ccsdk.features.sdnr.wt.common.database.HtDatabaseClient;
+import org.onap.ccsdk.features.sdnr.wt.devicemanager.ne.factory.FactoryRegistration;
+import org.onap.ccsdk.features.sdnr.wt.devicemanager.service.NetconfNetworkElementService;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+public class DeviceManagerOnf14Impl implements AutoCloseable {
+
+ private static final Logger LOG = LoggerFactory.getLogger(DeviceManagerOnf14Impl.class);
+ private static final String APPLICATION_NAME = "DeviceManagerOnf14";
+ @SuppressWarnings("unused")
+ private static final String CONFIGURATIONFILE = "etc/devicemanager-onf14.properties";
+
+
+ private NetconfNetworkElementService netconfNetworkElementService;
+
+ private HtDatabaseClient htDatabaseClient;
+ private Boolean devicemanagerInitializationOk = false;
+ private FactoryRegistration<Onf14NetworkElementFactory> resOnf;
+
+ // Blueprint begin
+ public DeviceManagerOnf14Impl() {
+ LOG.info("Creating provider for {}", APPLICATION_NAME);
+ resOnf = null;
+ }
+
+ public void setNetconfNetworkElementService(NetconfNetworkElementService netconfNetworkElementService) {
+ this.netconfNetworkElementService = netconfNetworkElementService;
+ }
+
+ public void init() throws Exception {
+
+ LOG.info("Session Initiated start {}", APPLICATION_NAME);
+
+ resOnf = netconfNetworkElementService.registerNetworkElementFactory(new Onf14NetworkElementFactory());
+
+
+ netconfNetworkElementService.writeToEventLog(APPLICATION_NAME, "startup", "done");
+ this.devicemanagerInitializationOk = true;
+
+ LOG.info("Session Initiated end. Initialization done {}", devicemanagerInitializationOk);
+ }
+ // Blueprint end
+
+ @Override
+ public void close() throws Exception {
+ LOG.info("closing ...");
+ close(htDatabaseClient);
+ close(resOnf);
+ LOG.info("closing done");
+ }
+
+ /**
+ * Used to close all Services, that should support AutoCloseable Pattern
+ *
+ * @param toClose
+ * @throws Exception
+ */
+ private void close(AutoCloseable... toCloseList) {
+ for (AutoCloseable element : toCloseList) {
+ if (element != null) {
+ try {
+ element.close();
+ } catch (Exception e) {
+ LOG.warn("Fail during close: ", e);
+ }
+ }
+ }
+ }
+}
diff --git a/sdnr/wt/devicemanager-onf14/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/onf14/impl/Onf14AirInterfaceNotificationListener.java b/sdnr/wt/devicemanager-onf14/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/onf14/impl/Onf14AirInterfaceNotificationListener.java
new file mode 100644
index 000000000..1663f61fe
--- /dev/null
+++ b/sdnr/wt/devicemanager-onf14/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/onf14/impl/Onf14AirInterfaceNotificationListener.java
@@ -0,0 +1,78 @@
+/*
+ * ============LICENSE_START=======================================================
+ * ONAP : ccsdk feature sdnr wt
+ * ================================================================================
+ * Copyright (C) 2020 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.impl;
+
+import org.onap.ccsdk.features.sdnr.wt.devicemanager.service.DeviceManagerServiceProvider;
+import org.onap.ccsdk.features.sdnr.wt.netconfnodestateservice.NetconfAccessor;
+import org.opendaylight.yang.gen.v1.urn.onf.yang.air._interface._2._0.rev200121.AirInterface20Listener;
+import org.opendaylight.yang.gen.v1.urn.onf.yang.air._interface._2._0.rev200121.AttributeValueChangedNotification;
+import org.opendaylight.yang.gen.v1.urn.onf.yang.air._interface._2._0.rev200121.ObjectCreationNotification;
+import org.opendaylight.yang.gen.v1.urn.onf.yang.air._interface._2._0.rev200121.ObjectDeletionNotification;
+import org.opendaylight.yang.gen.v1.urn.onf.yang.air._interface._2._0.rev200121.ProblemNotification;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+public class Onf14AirInterfaceNotificationListener implements AirInterface20Listener {
+
+ private static final Logger log = LoggerFactory.getLogger(Onf14AirInterfaceNotificationListener.class);
+
+ private final NetconfAccessor netconfAccessor;
+ private final DeviceManagerServiceProvider serviceProvider;
+
+ public Onf14AirInterfaceNotificationListener(NetconfAccessor netconfAccessor,
+ DeviceManagerServiceProvider serviceProvider) {
+ this.netconfAccessor = netconfAccessor;
+ this.serviceProvider = serviceProvider;
+ }
+
+ @Override
+ public void onObjectDeletionNotification(ObjectDeletionNotification notification) {
+ // TODO Auto-generated method stub
+ // this type of notification is not yet supported
+ log.debug("Got event of type :: {}", ObjectDeletionNotification.class.getSimpleName());
+ }
+
+ @Override
+ public void onProblemNotification(ProblemNotification notification) {
+ log.debug("Got event of type :: {}", ProblemNotification.class.getSimpleName());
+
+ serviceProvider.getFaultService().faultNotification(netconfAccessor.getNodeId(), notification.getCounter(),
+ notification.getTimestamp(), notification.getObjectIdRef().getValue(), notification.getProblem(),
+ Onf14NetworkElement.mapSeverity(notification.getSeverity()));
+
+ }
+
+ @Override
+ public void onAttributeValueChangedNotification(AttributeValueChangedNotification notification) {
+ // TODO Auto-generated method stub
+ // this type of notification is not yet supported
+ log.debug("Got event of type :: {}", AttributeValueChangedNotification.class.getSimpleName());
+ }
+
+ @Override
+ public void onObjectCreationNotification(ObjectCreationNotification notification) {
+ // TODO Auto-generated method stub
+ // this type of notification is not yet supported
+ log.debug("Got event of type :: {}", ObjectCreationNotification.class.getSimpleName());
+ }
+
+}
diff --git a/sdnr/wt/devicemanager-onf14/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/onf14/impl/Onf14NetworkElement.java b/sdnr/wt/devicemanager-onf14/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/onf14/impl/Onf14NetworkElement.java
new file mode 100644
index 000000000..92840fb3c
--- /dev/null
+++ b/sdnr/wt/devicemanager-onf14/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/onf14/impl/Onf14NetworkElement.java
@@ -0,0 +1,382 @@
+/*
+ * ============LICENSE_START========================================================================
+ * ONAP : ccsdk feature sdnr wt
+ * =================================================================================================
+ * Copyright (C) 2020 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.impl;
+
+import java.util.ArrayList;
+import java.util.List;
+import java.util.Optional;
+import org.eclipse.jdt.annotation.NonNull;
+import org.eclipse.jdt.annotation.Nullable;
+import org.onap.ccsdk.features.sdnr.wt.dataprovider.model.DataProvider;
+import org.onap.ccsdk.features.sdnr.wt.devicemanager.ne.service.NetworkElement;
+import org.onap.ccsdk.features.sdnr.wt.devicemanager.ne.service.NetworkElementService;
+import org.onap.ccsdk.features.sdnr.wt.devicemanager.service.DeviceManagerServiceProvider;
+import org.onap.ccsdk.features.sdnr.wt.devicemanager.service.FaultService;
+import org.onap.ccsdk.features.sdnr.wt.devicemanager.types.FaultData;
+import org.onap.ccsdk.features.sdnr.wt.netconfnodestateservice.NetconfAccessor;
+import org.opendaylight.mdsal.common.api.LogicalDatastoreType;
+import org.opendaylight.yang.gen.v1.urn.onf.yang.air._interface._2._0.rev200121.LAYERPROTOCOLNAMETYPEAIRLAYER;
+import org.opendaylight.yang.gen.v1.urn.onf.yang.air._interface._2._0.rev200121.LayerProtocol1;
+import org.opendaylight.yang.gen.v1.urn.onf.yang.air._interface._2._0.rev200121.SEVERITYTYPE;
+import org.opendaylight.yang.gen.v1.urn.onf.yang.air._interface._2._0.rev200121.SEVERITYTYPECRITICAL;
+import org.opendaylight.yang.gen.v1.urn.onf.yang.air._interface._2._0.rev200121.SEVERITYTYPEMAJOR;
+import org.opendaylight.yang.gen.v1.urn.onf.yang.air._interface._2._0.rev200121.SEVERITYTYPEMINOR;
+import org.opendaylight.yang.gen.v1.urn.onf.yang.air._interface._2._0.rev200121.SEVERITYTYPENONALARMED;
+import org.opendaylight.yang.gen.v1.urn.onf.yang.air._interface._2._0.rev200121.SEVERITYTYPEWARNING;
+import org.opendaylight.yang.gen.v1.urn.onf.yang.air._interface._2._0.rev200121.air._interface.current.problems.CurrentProblemList;
+import org.opendaylight.yang.gen.v1.urn.onf.yang.air._interface._2._0.rev200121.air._interface.lp.spec.AirInterfacePac;
+import org.opendaylight.yang.gen.v1.urn.onf.yang.air._interface._2._0.rev200121.air._interface.pac.AirInterfaceCurrentProblems;
+import org.opendaylight.yang.gen.v1.urn.onf.yang.core.model._1._4.rev191127.ControlConstruct;
+import org.opendaylight.yang.gen.v1.urn.onf.yang.core.model._1._4.rev191127.LAYERPROTOCOLNAMETYPE;
+import org.opendaylight.yang.gen.v1.urn.onf.yang.core.model._1._4.rev191127.UniversalId;
+import org.opendaylight.yang.gen.v1.urn.onf.yang.core.model._1._4.rev191127.control.construct.Equipment;
+import org.opendaylight.yang.gen.v1.urn.onf.yang.core.model._1._4.rev191127.control.construct.EquipmentKey;
+import org.opendaylight.yang.gen.v1.urn.onf.yang.core.model._1._4.rev191127.control.construct.LogicalTerminationPoint;
+import org.opendaylight.yang.gen.v1.urn.onf.yang.core.model._1._4.rev191127.control.construct.LogicalTerminationPointKey;
+import org.opendaylight.yang.gen.v1.urn.onf.yang.core.model._1._4.rev191127.equipment.ContainedHolder;
+import org.opendaylight.yang.gen.v1.urn.onf.yang.core.model._1._4.rev191127.logical.termination.point.LayerProtocol;
+import org.opendaylight.yang.gen.v1.urn.onf.yang.core.model._1._4.rev191127.logical.termination.point.LayerProtocolKey;
+import org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.data.provider.rev190801.NetworkElementDeviceType;
+import org.opendaylight.yang.gen.v1.urn.tbd.params.xml.ns.yang.network.topology.rev131021.NodeId;
+import org.opendaylight.yangtools.concepts.ListenerRegistration;
+import org.opendaylight.yangtools.yang.binding.InstanceIdentifier;
+import org.opendaylight.yangtools.yang.binding.NotificationListener;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+/**
+ * Repesentation of ONF Core model 1.4 device Top level element is "ControlConstruct" (replaces "NetworkElement" of
+ * older ONF Version)
+ */
+public class Onf14NetworkElement implements NetworkElement {
+
+ private static final Logger log = LoggerFactory.getLogger(Onf14NetworkElement.class);
+
+ protected static final InstanceIdentifier<ControlConstruct> CONTROLCONSTRUCT_IID =
+ InstanceIdentifier.builder(ControlConstruct.class).build();
+
+ private static final int EQUIPMENTROOTLEVEL = 0;
+
+ private final NetconfAccessor netconfAccessor;
+ private final DataProvider databaseService;
+ private final Onf14ToInternalDataModel onf14Mapper;
+ private final @NonNull FaultService faultService;
+
+ // for storing the Equipment UUIDs that are inserted in the DB
+ private final List<String> equipmentUuidList = new ArrayList<String>();
+
+ // air interface related members
+ private final List<TechnologySpecificPacKeys> airInterfaceList = new ArrayList<TechnologySpecificPacKeys>();
+ private ListenerRegistration<NotificationListener> airInterfaceNotificationListenerHandler;
+ private @NonNull final Onf14AirInterfaceNotificationListener airInterfaceNotificationListener;
+
+ Onf14NetworkElement(NetconfAccessor netconfAccess, DeviceManagerServiceProvider serviceProvider) {
+ log.info("Create {}", Onf14NetworkElement.class.getSimpleName());
+ this.netconfAccessor = netconfAccess;
+ this.databaseService = serviceProvider.getDataProvider();
+ this.faultService = serviceProvider.getFaultService();
+ this.onf14Mapper = new Onf14ToInternalDataModel();
+ this.airInterfaceNotificationListenerHandler = null;
+ airInterfaceNotificationListener = new Onf14AirInterfaceNotificationListener(netconfAccess, serviceProvider);
+ }
+
+ public void initialReadFromNetworkElement() {
+
+ // reading the inventory (CoreModel 1.4 Equipment Model) and adding it to the DB
+ readEquipmentData();
+
+ FaultData resultList = new FaultData();
+
+ int problems = faultService.removeAllCurrentProblemsOfNode(netconfAccessor.getNodeId());
+ log.debug("Removed all {} problems from database at registration", problems);
+
+ readAllAirInterfaceCurrentProblems(resultList);
+ log.debug("NETCONF read current problems completed. Got back {} problems.", resultList.size());
+
+ faultService.initCurrentProblemStatus(netconfAccessor.getNodeId(), resultList);
+ log.debug("DB write current problems completed");
+
+ }
+
+ public void readAllAirInterfaceCurrentProblems(FaultData resultList) {
+
+ int idxStart; // Start index for debug messages
+
+ for (TechnologySpecificPacKeys key : airInterfaceList) {
+ idxStart = resultList.size();
+
+ readAirInterfaceCurrentProblemForLtp(key.getLtpUuid(), key.getLocalId(), resultList);
+ debugResultList(key.getLtpUuid().getValue(), resultList, idxStart);
+ }
+ }
+
+ @Override
+ public void register() {
+ initialReadFromNetworkElement();
+ // Register netconf stream
+ airInterfaceNotificationListenerHandler =
+ netconfAccessor.doRegisterNotificationListener(airInterfaceNotificationListener);
+ netconfAccessor.registerNotificationsStream(NetconfAccessor.DefaultNotificationsStream);
+ }
+
+ @Override
+ public void deregister() {}
+
+
+ @Override
+ public NodeId getNodeId() {
+ return netconfAccessor.getNodeId();
+ }
+
+ @Override
+ public <L extends NetworkElementService> Optional<L> getService(Class<L> clazz) {
+ return Optional.empty();
+ }
+
+ @Override
+ public void warmstart() {}
+
+ @Override
+ public Optional<NetconfAccessor> getAcessor() {
+ return Optional.of(netconfAccessor);
+ }
+
+ @Override
+ public NetworkElementDeviceType getDeviceType() {
+ return NetworkElementDeviceType.Wireless;
+ }
+
+ public static org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.data.provider.rev190801.SeverityType mapSeverity(
+ Class<? extends SEVERITYTYPE> severity) {
+
+ if (severity != null) {
+ if (severity.getTypeName() == SEVERITYTYPECRITICAL.class.getName()) {
+ return org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.data.provider.rev190801.SeverityType.Critical;
+ } else if (severity.getTypeName() == SEVERITYTYPEMAJOR.class.getName()) {
+ return org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.data.provider.rev190801.SeverityType.Major;
+ } else if (severity.getTypeName() == SEVERITYTYPEMINOR.class.getName()) {
+ return org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.data.provider.rev190801.SeverityType.Minor;
+ } else if (severity.getTypeName() == SEVERITYTYPEWARNING.class.getName()) {
+ return org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.data.provider.rev190801.SeverityType.Warning;
+ } else if (severity.getTypeName() == SEVERITYTYPENONALARMED.class.getName()) {
+ return org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.data.provider.rev190801.SeverityType.NonAlarmed;
+ }
+ }
+
+ return org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.data.provider.rev190801.SeverityType.NonAlarmed;
+ }
+
+ private void readEquipmentData() {
+
+ Optional<ControlConstruct> controlConstruct = readControlConstruct(netconfAccessor);
+
+ if (controlConstruct.isPresent()) {
+ // the top-level-equipment list contains the root objects of the Equipment Model
+ log.debug("Getting list of topLevelEquipment for mountpoint {}", netconfAccessor.getNodeId());
+ @Nullable
+ List<UniversalId> topLevelEquipment = controlConstruct.get().getTopLevelEquipment();
+
+ if (topLevelEquipment != null) {
+ for (UniversalId uuid : topLevelEquipment) {
+ log.debug("Got back topLevelEquipment with uuid {}", uuid.getValue());
+
+ // adding all root Equipment objects to the DB
+ @Nullable
+ Equipment equipmentInstance = readEquipmentInstance(netconfAccessor, uuid);
+ if (equipmentInstance != null) {
+ // recursively adding the root equipment and all its children into the DB
+ addEquipmentToDb(equipmentInstance, null, EQUIPMENTROOTLEVEL);
+ }
+ }
+ }
+ }
+
+ // storing all the airInterface LTP UUIDs internally, for later usage
+ readAirInterfaceKeys(controlConstruct);
+ }
+
+ private void addEquipmentToDb(Equipment currentEq, Equipment parentEq, long treeLevel) {
+
+ // if the Equipment UUID is already in the list, it was already processed
+ // needed for solving possible circular dependencies
+ if (equipmentUuidList.contains(currentEq.getUuid().getValue())) {
+ log.debug("Not adding equipment with uuid {} because it was aleady added...",
+ currentEq.getUuid().getValue());
+ return;
+ }
+
+ // we add this to our internal list, such that we avoid circular dependencies
+ equipmentUuidList.add(currentEq.getUuid().getValue());
+ log.debug("Adding equipment with uuid {} to the database...", currentEq.getUuid().getValue());
+
+ // we add our current equipment to the database
+ databaseService.writeInventory(
+ onf14Mapper.getInternalEquipment(netconfAccessor.getNodeId(), currentEq, parentEq, treeLevel));
+
+ // we iterate the kids of our current equipment and add them to the database recursively
+ // the actual reference is here: /core-model:control-construct/equipment/contained-holder/occupying-fru
+ @NonNull
+ List<ContainedHolder> holderList = currentEq.nonnullContainedHolder();
+
+ for (ContainedHolder holder : holderList) {
+ @Nullable
+ UniversalId occupyingFru = holder.getOccupyingFru();
+ if (occupyingFru != null) {
+ @Nullable
+ Equipment childEq = readEquipmentInstance(netconfAccessor, occupyingFru);
+
+ if (childEq != null) {
+ // current becomes parent and tree level increases by 1
+ addEquipmentToDb(childEq, currentEq, treeLevel + 1);
+ }
+ }
+ }
+ }
+
+ private void readAirInterfaceKeys(Optional<ControlConstruct> controlConstruct) {
+
+ if (controlConstruct.isPresent()) {
+ @NonNull
+ List<LogicalTerminationPoint> ltpList = controlConstruct.get().nonnullLogicalTerminationPoint();
+ log.debug("Iterating the LTP list for node {}", netconfAccessor.getNodeId().getValue());
+
+ // iterating all the Logical Termination Point list
+ for (LogicalTerminationPoint ltp : ltpList) {
+ @NonNull
+ List<LayerProtocol> lpList = ltp.nonnullLayerProtocol();
+ // the Layer Protocol list should contain only one item, since we have an 1:1 relationship between the LTP and the LP
+ if (lpList.size() != 1) {
+ log.debug("Layer protocol has no 1:1 relationship with the LTP.");
+ return;
+ }
+ // accessing the LP, which should be only 1
+ LayerProtocol lp = lpList.get(0);
+ @Nullable
+ Class<? extends LAYERPROTOCOLNAMETYPE> layerProtocolName = lp.getLayerProtocolName();
+ if (layerProtocolName != null) {
+ // it the LTP has an airInterface technology extension, the layer protocol name is air-layer
+ if (layerProtocolName.getTypeName() == LAYERPROTOCOLNAMETYPEAIRLAYER.class.getName()) {
+ TechnologySpecificPacKeys airInterfaceKey =
+ new TechnologySpecificPacKeys(ltp.getUuid(), lp.getLocalId());
+ airInterfaceList.add(airInterfaceKey);
+ log.debug("Adding Ltp with uuid {} and local-id {} to the air-interface list",
+ ltp.getUuid().getValue(), lp.getLocalId());
+ }
+ }
+ }
+ }
+ }
+
+ private void readAirInterfaceCurrentProblemForLtp(UniversalId ltpUuid, String localId, FaultData resultList) {
+
+ final Class<AirInterfacePac> clazzPac = AirInterfacePac.class;
+
+ log.info("DBRead Get current problems for class {} from mountpoint {} for LTP uuid {} and local-id {}",
+ clazzPac.getSimpleName(), netconfAccessor.getNodeId().getValue(), ltpUuid.getValue(), localId);
+
+ // constructing the IID needs the augmentation exposed byy the air-interface-2-0 model
+ InstanceIdentifier<AirInterfaceCurrentProblems> airInterfaceCurrentProblem_IID =
+ InstanceIdentifier.builder(ControlConstruct.class)
+ .child(LogicalTerminationPoint.class, new LogicalTerminationPointKey(ltpUuid))
+ .child(LayerProtocol.class, new LayerProtocolKey(localId)).augmentation(LayerProtocol1.class)
+ .child(AirInterfacePac.class).child(AirInterfaceCurrentProblems.class).build();
+
+ // reading all the current-problems list for this specific LTP and LP
+ AirInterfaceCurrentProblems problems = netconfAccessor.getTransactionUtils().readData(
+ netconfAccessor.getDataBroker(), LogicalDatastoreType.OPERATIONAL, airInterfaceCurrentProblem_IID);
+
+ if (problems == null) {
+ log.debug("DBRead Id {} no AirInterfaceCurrentProblems", ltpUuid);
+ } else if (problems.getCurrentProblemList() == null) {
+ log.debug("DBRead Id {} empty CurrentProblemList", ltpUuid);
+ } else {
+ for (CurrentProblemList problem : problems.nonnullCurrentProblemList()) {
+ resultList.add(netconfAccessor.getNodeId(), (int) problem.getSequenceNumber(), problem.getTimestamp(),
+ ltpUuid.getValue(), problem.getProblemName(), mapSeverity(problem.getProblemSeverity()));
+ }
+ }
+ }
+
+ private Optional<ControlConstruct> readControlConstruct(NetconfAccessor netconfAccessor) {
+ return Optional.ofNullable(netconfAccessor.getTransactionUtils().readData(netconfAccessor.getDataBroker(),
+ LogicalDatastoreType.OPERATIONAL, CONTROLCONSTRUCT_IID));
+ }
+
+ private @Nullable Equipment readEquipmentInstance(NetconfAccessor accessData, UniversalId equipmentUuid) {
+
+ final Class<?> clazzPac = Equipment.class;
+
+ log.info("DBRead Get equipment for class {} from mountpoint {} for uuid {}", clazzPac.getSimpleName(),
+ accessData.getNodeId().getValue(), equipmentUuid.getValue());
+
+ InstanceIdentifier<Equipment> equipmentIID = InstanceIdentifier.builder(ControlConstruct.class)
+ .child(Equipment.class, new EquipmentKey(equipmentUuid)).build();
+
+ return accessData.getTransactionUtils().readData(accessData.getDataBroker(), LogicalDatastoreType.OPERATIONAL,
+ equipmentIID);
+ }
+
+ // defining a structure that can map the LP local-id and its corresponding LTP uuid
+ private class TechnologySpecificPacKeys {
+
+ private UniversalId ltpUuid;
+ private String localId;
+
+ public TechnologySpecificPacKeys(UniversalId uuid, String lId) {
+ this.ltpUuid = uuid;
+ this.localId = lId;
+ }
+
+ public UniversalId getLtpUuid() {
+ return ltpUuid;
+ }
+
+ public String getLocalId() {
+ return localId;
+ }
+
+ public void setLtpUuid(UniversalId uuid) {
+ this.ltpUuid = uuid;
+ }
+
+ public void setLocalId(String lId) {
+ this.localId = lId;
+ }
+ }
+
+
+ /**
+ * LOG the newly added problems of the interface pac
+ *
+ * @param idxStart
+ * @param uuid
+ * @param resultList
+ */
+ private void debugResultList(String uuid, FaultData resultList, int idxStart) {
+ StringBuilder sb = new StringBuilder();
+ int idx = 0;
+ for (int t = idxStart; t < resultList.size(); t++) {
+ sb.append(idx++);
+ sb.append(":{");
+ sb.append(resultList.get(t));
+ sb.append('}');
+ }
+ log.debug("Found problems {} {}", uuid, sb);
+ }
+
+}
diff --git a/sdnr/wt/devicemanager-onf14/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/onf14/impl/Onf14NetworkElementFactory.java b/sdnr/wt/devicemanager-onf14/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/onf14/impl/Onf14NetworkElementFactory.java
new file mode 100644
index 000000000..5505cecd6
--- /dev/null
+++ b/sdnr/wt/devicemanager-onf14/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/onf14/impl/Onf14NetworkElementFactory.java
@@ -0,0 +1,43 @@
+/*
+ * ============LICENSE_START========================================================================
+ * ONAP : ccsdk feature sdnr wt
+ * =================================================================================================
+ * Copyright (C) 2020 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.impl;
+
+import java.util.Optional;
+import org.onap.ccsdk.features.sdnr.wt.devicemanager.ne.factory.NetworkElementFactory;
+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.opendaylight.yang.gen.v1.urn.onf.yang.core.model._1._4.rev191127.ControlConstruct;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+public class Onf14NetworkElementFactory implements NetworkElementFactory {
+
+ private static final Logger log = LoggerFactory.getLogger(Onf14NetworkElementFactory.class);
+
+ @Override
+ public Optional<NetworkElement> create(NetconfAccessor acessor, DeviceManagerServiceProvider serviceProvider) {
+ if (acessor.getCapabilites().isSupportingNamespace(ControlConstruct.QNAME)) {
+ log.info("Create device {} ", Onf14NetworkElement.class.getName());
+ return Optional.of(new Onf14NetworkElement(acessor, serviceProvider));
+ } else {
+ return Optional.empty();
+ }
+ }
+}
diff --git a/sdnr/wt/devicemanager-onf14/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/onf14/impl/Onf14ToInternalDataModel.java b/sdnr/wt/devicemanager-onf14/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/onf14/impl/Onf14ToInternalDataModel.java
new file mode 100644
index 000000000..ad42f03ca
--- /dev/null
+++ b/sdnr/wt/devicemanager-onf14/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/onf14/impl/Onf14ToInternalDataModel.java
@@ -0,0 +1,128 @@
+/*
+ * ============LICENSE_START========================================================================
+ * ONAP : ccsdk feature sdnr wt
+ * =================================================================================================
+ * Copyright (C) 2020 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.impl;
+
+import java.util.ArrayList;
+import java.util.List;
+import org.eclipse.jdt.annotation.NonNull;
+import org.eclipse.jdt.annotation.Nullable;
+import org.opendaylight.yang.gen.v1.urn.onf.yang.core.model._1._4.rev191127.Equipment;
+import org.opendaylight.yang.gen.v1.urn.onf.yang.core.model._1._4.rev191127.EquipmentInstance;
+import org.opendaylight.yang.gen.v1.urn.onf.yang.core.model._1._4.rev191127.EquipmentType;
+import org.opendaylight.yang.gen.v1.urn.onf.yang.core.model._1._4.rev191127.ManufacturedThing;
+import org.opendaylight.yang.gen.v1.urn.onf.yang.core.model._1._4.rev191127.ManufacturerProperties;
+import org.opendaylight.yang.gen.v1.urn.onf.yang.core.model._1._4.rev191127.UniversalId;
+import org.opendaylight.yang.gen.v1.urn.onf.yang.core.model._1._4.rev191127.equipment.ActualEquipment;
+import org.opendaylight.yang.gen.v1.urn.onf.yang.core.model._1._4.rev191127.equipment.ContainedHolder;
+import org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.data.provider.rev190801.Inventory;
+import org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.data.provider.rev190801.InventoryBuilder;
+import org.opendaylight.yang.gen.v1.urn.tbd.params.xml.ns.yang.network.topology.rev131021.NodeId;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+/**
+ * @author alexs
+ *
+ */
+public class Onf14ToInternalDataModel {
+
+ private static final Logger log = LoggerFactory.getLogger(Onf14ToInternalDataModel.class);
+
+ public Inventory getInternalEquipment(NodeId nodeId, Equipment currentEq, Equipment parentEq, long treeLevel) {
+
+ InventoryBuilder inventoryBuilder = new InventoryBuilder();
+
+ @Nullable
+ ActualEquipment component = currentEq.getActualEquipment();
+ if (component != null) {
+
+ // General
+ inventoryBuilder.setNodeId(nodeId.getValue());
+
+ inventoryBuilder.setTreeLevel(treeLevel);
+ inventoryBuilder.setUuid(currentEq.getUuid().getValue());
+
+ if (parentEq != null) {
+ inventoryBuilder.setParentUuid(parentEq.getUuid().getValue());
+ } else {
+ inventoryBuilder.setParentUuid("None");
+ }
+
+ List<String> containedHolderKeyList = new ArrayList<String>();
+ @NonNull
+ List<ContainedHolder> containedHolderList = currentEq.nonnullContainedHolder();
+ for (ContainedHolder holder : containedHolderList) {
+ @Nullable
+ UniversalId occupyingFru = holder.getOccupyingFru();
+
+ if (occupyingFru != null) {
+ containedHolderKeyList.add(occupyingFru.getValue());
+ }
+ }
+ inventoryBuilder.setContainedHolder(containedHolderKeyList);
+
+ @Nullable
+ ManufacturedThing manThing = component.getManufacturedThing();
+ if (manThing != null) {
+ // Manufacturer properties
+ @Nullable
+ ManufacturerProperties manProp = manThing.getManufacturerProperties();
+ if (manProp != null) {
+ inventoryBuilder.setManufacturerName(manProp.getManufacturerName());
+ inventoryBuilder.setManufacturerIdentifier(manProp.getManufacturerIdentifier());
+ } else {
+ log.debug("manufacturer-properties is not present in Equipment with uuid={}",
+ currentEq.getUuid().getValue());
+ }
+
+ // Equipment instance
+ @Nullable
+ EquipmentInstance eqInstance = manThing.getEquipmentInstance();
+ if (eqInstance != null) {
+ inventoryBuilder.setSerial(eqInstance.getSerialNumber());
+ inventoryBuilder.setDate(eqInstance.getManufactureDate().getValue());
+ } else {
+ log.debug("equipment-instance is not present in Equipment with uuid={}",
+ currentEq.getUuid().getValue());
+ }
+
+ // Equipment type
+ @Nullable
+ EquipmentType eqType = manThing.getEquipmentType();
+ if (eqType != null) {
+ inventoryBuilder.setVersion(eqType.getVersion());
+ inventoryBuilder.setDescription(eqType.getDescription());
+ inventoryBuilder.setPartTypeId(eqType.getPartTypeIdentifier());
+ inventoryBuilder.setModelIdentifier(eqType.getModelIdentifier());
+ inventoryBuilder.setTypeName(eqType.getTypeName());
+ } else {
+ log.debug("equipment-type is not present in Equipment with uuid={}",
+ currentEq.getUuid().getValue());
+ }
+ } else {
+ log.debug("manufactured-thing is not present in Equipment with uuid={}",
+ currentEq.getUuid().getValue());
+ }
+ } else {
+ log.debug("actual-equipment is not present in Equipment with uuid={}", currentEq.getUuid().getValue());
+ }
+
+ return inventoryBuilder.build();
+ }
+
+}
diff --git a/sdnr/wt/devicemanager-onf14/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/onf14/yang/Control.java b/sdnr/wt/devicemanager-onf14/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/onf14/yang/Control.java
new file mode 100644
index 000000000..fc4de9104
--- /dev/null
+++ b/sdnr/wt/devicemanager-onf14/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/onf14/yang/Control.java
@@ -0,0 +1,26 @@
+/*
+ * ============LICENSE_START========================================================================
+ * ONAP : ccsdk feature sdnr wt
+ * =================================================================================================
+ * Copyright (C) 2019 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.yang;
+
+public class Control {
+
+ public class MaxAlarmStatusChanges {
+
+ }
+
+}
diff --git a/sdnr/wt/devicemanager-onf14/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/onf14/yang/OperatorState.java b/sdnr/wt/devicemanager-onf14/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/onf14/yang/OperatorState.java
new file mode 100644
index 000000000..9b516bb67
--- /dev/null
+++ b/sdnr/wt/devicemanager-onf14/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/onf14/yang/OperatorState.java
@@ -0,0 +1,22 @@
+/*
+ * ============LICENSE_START========================================================================
+ * ONAP : ccsdk feature sdnr wt
+ * =================================================================================================
+ * Copyright (C) 2019 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.yang;
+
+public enum OperatorState {
+
+}
diff --git a/sdnr/wt/devicemanager-onf14/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/onf14/yang/Resource.java b/sdnr/wt/devicemanager-onf14/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/onf14/yang/Resource.java
new file mode 100644
index 000000000..7966c1c71
--- /dev/null
+++ b/sdnr/wt/devicemanager-onf14/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/onf14/yang/Resource.java
@@ -0,0 +1,22 @@
+/*
+ * ============LICENSE_START========================================================================
+ * ONAP : ccsdk feature sdnr wt
+ * =================================================================================================
+ * Copyright (C) 2019 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.yang;
+
+public class Resource {
+
+}
diff --git a/sdnr/wt/devicemanager-onf14/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/onf14/yang/ResourceMatch.java b/sdnr/wt/devicemanager-onf14/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/onf14/yang/ResourceMatch.java
new file mode 100644
index 000000000..c7e9103a1
--- /dev/null
+++ b/sdnr/wt/devicemanager-onf14/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/onf14/yang/ResourceMatch.java
@@ -0,0 +1,22 @@
+/*
+ * ============LICENSE_START========================================================================
+ * ONAP : ccsdk feature sdnr wt
+ * =================================================================================================
+ * Copyright (C) 2019 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.yang;
+
+public class ResourceMatch {
+
+}
diff --git a/sdnr/wt/devicemanager-onf14/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/onf14/yang/SeverityWithClear.java b/sdnr/wt/devicemanager-onf14/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/onf14/yang/SeverityWithClear.java
new file mode 100644
index 000000000..1b39bf928
--- /dev/null
+++ b/sdnr/wt/devicemanager-onf14/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/onf14/yang/SeverityWithClear.java
@@ -0,0 +1,22 @@
+/*
+ * ============LICENSE_START========================================================================
+ * ONAP : ccsdk feature sdnr wt
+ * =================================================================================================
+ * Copyright (C) 2019 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.yang;
+
+public enum SeverityWithClear {
+
+}
diff --git a/sdnr/wt/devicemanager-onf14/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/onf14/yang/package-info.java b/sdnr/wt/devicemanager-onf14/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/onf14/yang/package-info.java
new file mode 100644
index 000000000..0769687e8
--- /dev/null
+++ b/sdnr/wt/devicemanager-onf14/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/onf14/yang/package-info.java
@@ -0,0 +1,18 @@
+/*
+ * ============LICENSE_START========================================================================
+ * ONAP : ccsdk feature sdnr wt
+ * =================================================================================================
+ * Copyright (C) 2019 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.yang;
diff --git a/sdnr/wt/devicemanager-onf14/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/ietf/params/xml/ns/yang/ietf/alarms/rev190911/OperatorStateBuilder.java b/sdnr/wt/devicemanager-onf14/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/ietf/params/xml/ns/yang/ietf/alarms/rev190911/OperatorStateBuilder.java
new file mode 100644
index 000000000..5859ebeb4
--- /dev/null
+++ b/sdnr/wt/devicemanager-onf14/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/ietf/params/xml/ns/yang/ietf/alarms/rev190911/OperatorStateBuilder.java
@@ -0,0 +1,26 @@
+package org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.alarms.rev190911;
+
+import java.lang.String;
+import java.lang.UnsupportedOperationException;
+
+import org.onap.ccsdk.features.sdnr.wt.devicemanager.onf14.yang.OperatorState;
+
+/**
+ * The purpose of generated class in src/main/java for Union types is to create new instances of unions from a string
+ * representation. In some cases it is very difficult to automate it since there can be unions such as (uint32 -
+ * uint16), or (string - uint32).
+ *
+ * The reason behind putting it under src/main/java is: This class is generated in form of a stub and needs to be
+ * finished by the user. This class is generated only once to prevent loss of user code.
+ *
+ */
+public class OperatorStateBuilder {
+ private OperatorStateBuilder() {
+ //Exists only to defeat instantiation.
+ }
+
+ public static OperatorState getDefaultInstance(String defaultValue) {
+ throw new UnsupportedOperationException("Not yet implemented");
+ }
+
+}
diff --git a/sdnr/wt/devicemanager-onf14/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/ietf/params/xml/ns/yang/ietf/alarms/rev190911/ResourceBuilder.java b/sdnr/wt/devicemanager-onf14/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/ietf/params/xml/ns/yang/ietf/alarms/rev190911/ResourceBuilder.java
new file mode 100644
index 000000000..f7c105f54
--- /dev/null
+++ b/sdnr/wt/devicemanager-onf14/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/ietf/params/xml/ns/yang/ietf/alarms/rev190911/ResourceBuilder.java
@@ -0,0 +1,26 @@
+package org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.alarms.rev190911;
+
+import java.lang.String;
+import java.lang.UnsupportedOperationException;
+
+import org.onap.ccsdk.features.sdnr.wt.devicemanager.onf14.yang.Resource;
+
+/**
+ * The purpose of generated class in src/main/java for Union types is to create new instances of unions from a string
+ * representation. In some cases it is very difficult to automate it since there can be unions such as (uint32 -
+ * uint16), or (string - uint32).
+ *
+ * The reason behind putting it under src/main/java is: This class is generated in form of a stub and needs to be
+ * finished by the user. This class is generated only once to prevent loss of user code.
+ *
+ */
+public class ResourceBuilder {
+ private ResourceBuilder() {
+ //Exists only to defeat instantiation.
+ }
+
+ public static Resource getDefaultInstance(String defaultValue) {
+ throw new UnsupportedOperationException("Not yet implemented");
+ }
+
+}
diff --git a/sdnr/wt/devicemanager-onf14/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/ietf/params/xml/ns/yang/ietf/alarms/rev190911/ResourceMatchBuilder.java b/sdnr/wt/devicemanager-onf14/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/ietf/params/xml/ns/yang/ietf/alarms/rev190911/ResourceMatchBuilder.java
new file mode 100644
index 000000000..bf0468b06
--- /dev/null
+++ b/sdnr/wt/devicemanager-onf14/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/ietf/params/xml/ns/yang/ietf/alarms/rev190911/ResourceMatchBuilder.java
@@ -0,0 +1,26 @@
+package org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.alarms.rev190911;
+
+import java.lang.String;
+import java.lang.UnsupportedOperationException;
+
+import org.onap.ccsdk.features.sdnr.wt.devicemanager.onf14.yang.ResourceMatch;
+
+/**
+ * The purpose of generated class in src/main/java for Union types is to create new instances of unions from a string
+ * representation. In some cases it is very difficult to automate it since there can be unions such as (uint32 -
+ * uint16), or (string - uint32).
+ *
+ * The reason behind putting it under src/main/java is: This class is generated in form of a stub and needs to be
+ * finished by the user. This class is generated only once to prevent loss of user code.
+ *
+ */
+public class ResourceMatchBuilder {
+ private ResourceMatchBuilder() {
+ //Exists only to defeat instantiation.
+ }
+
+ public static ResourceMatch getDefaultInstance(String defaultValue) {
+ throw new UnsupportedOperationException("Not yet implemented");
+ }
+
+}
diff --git a/sdnr/wt/devicemanager-onf14/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/ietf/params/xml/ns/yang/ietf/alarms/rev190911/SeverityWithClearBuilder.java b/sdnr/wt/devicemanager-onf14/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/ietf/params/xml/ns/yang/ietf/alarms/rev190911/SeverityWithClearBuilder.java
new file mode 100644
index 000000000..cc2ba820a
--- /dev/null
+++ b/sdnr/wt/devicemanager-onf14/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/ietf/params/xml/ns/yang/ietf/alarms/rev190911/SeverityWithClearBuilder.java
@@ -0,0 +1,26 @@
+package org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.alarms.rev190911;
+
+import java.lang.String;
+import java.lang.UnsupportedOperationException;
+
+import org.onap.ccsdk.features.sdnr.wt.devicemanager.onf14.yang.SeverityWithClear;
+
+/**
+ * The purpose of generated class in src/main/java for Union types is to create new instances of unions from a string
+ * representation. In some cases it is very difficult to automate it since there can be unions such as (uint32 -
+ * uint16), or (string - uint32).
+ *
+ * The reason behind putting it under src/main/java is: This class is generated in form of a stub and needs to be
+ * finished by the user. This class is generated only once to prevent loss of user code.
+ *
+ */
+public class SeverityWithClearBuilder {
+ private SeverityWithClearBuilder() {
+ //Exists only to defeat instantiation.
+ }
+
+ public static SeverityWithClear getDefaultInstance(String defaultValue) {
+ throw new UnsupportedOperationException("Not yet implemented");
+ }
+
+}
diff --git a/sdnr/wt/devicemanager-onf14/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/ietf/params/xml/ns/yang/ietf/alarms/rev190911/alarms/ControlMaxAlarmStatusChangesBuilder.java b/sdnr/wt/devicemanager-onf14/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/ietf/params/xml/ns/yang/ietf/alarms/rev190911/alarms/ControlMaxAlarmStatusChangesBuilder.java
new file mode 100644
index 000000000..6bf2fa030
--- /dev/null
+++ b/sdnr/wt/devicemanager-onf14/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/ietf/params/xml/ns/yang/ietf/alarms/rev190911/alarms/ControlMaxAlarmStatusChangesBuilder.java
@@ -0,0 +1,26 @@
+package org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.alarms.rev190911.alarms;
+
+import java.lang.String;
+import java.lang.UnsupportedOperationException;
+
+import org.onap.ccsdk.features.sdnr.wt.devicemanager.onf14.yang.Control;
+
+/**
+ * The purpose of generated class in src/main/java for Union types is to create new instances of unions from a string
+ * representation. In some cases it is very difficult to automate it since there can be unions such as (uint32 -
+ * uint16), or (string - uint32).
+ *
+ * The reason behind putting it under src/main/java is: This class is generated in form of a stub and needs to be
+ * finished by the user. This class is generated only once to prevent loss of user code.
+ *
+ */
+public class ControlMaxAlarmStatusChangesBuilder {
+ private ControlMaxAlarmStatusChangesBuilder() {
+ //Exists only to defeat instantiation.
+ }
+
+ public static Control.MaxAlarmStatusChanges getDefaultInstance(String defaultValue) {
+ throw new UnsupportedOperationException("Not yet implemented");
+ }
+
+}