aboutsummaryrefslogtreecommitdiffstats
path: root/sdnr/wt/devicemanager-o-ran-sc
diff options
context:
space:
mode:
authorRavi Pendurty <ravi.pendurty@highstreet-technologies.com>2021-08-23 17:02:34 +0530
committerRavi Pendurty <ravi.pendurty@highstreet-technologies.com>2021-08-23 17:02:48 +0530
commitf9a40915be030cd446a843b26a603907538ab971 (patch)
tree6e411bb5076fd630f0b4d7b5e030e02d5a6b1fdf /sdnr/wt/devicemanager-o-ran-sc
parent6b0b73e7921017f294d3b6ca6df3ba671d32749f (diff)
Fix severity mapping in VES Fault
Fix severity mapping in VES Fault Issue-ID: CCSDK-3427 Signed-off-by: Ravi Pendurty <ravi.pendurty@highstreet-technologies.com> Change-Id: I3491fb0e730fc5a1eadb59728f6925acdf22ef43 Signed-off-by: Ravi Pendurty <ravi.pendurty@highstreet-technologies.com>
Diffstat (limited to 'sdnr/wt/devicemanager-o-ran-sc')
-rw-r--r--sdnr/wt/devicemanager-o-ran-sc/o-ran/ru-fh/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/oran/impl/ORanFaultToVESFaultMapper.java6
-rw-r--r--sdnr/wt/devicemanager-o-ran-sc/o-ran/ru-fh/provider/src/test/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/oran/impl/TestAlarmNotif.java3
2 files changed, 6 insertions, 3 deletions
diff --git a/sdnr/wt/devicemanager-o-ran-sc/o-ran/ru-fh/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/oran/impl/ORanFaultToVESFaultMapper.java b/sdnr/wt/devicemanager-o-ran-sc/o-ran/ru-fh/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/oran/impl/ORanFaultToVESFaultMapper.java
index 0d68bdbf5..ec8eaa7b7 100644
--- a/sdnr/wt/devicemanager-o-ran-sc/o-ran/ru-fh/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/oran/impl/ORanFaultToVESFaultMapper.java
+++ b/sdnr/wt/devicemanager-o-ran-sc/o-ran/ru-fh/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/oran/impl/ORanFaultToVESFaultMapper.java
@@ -148,7 +148,11 @@ public class ORanFaultToVESFaultMapper {
vesFaultFields.setAlarmCondition(alarmNotif.getFaultId().toString());
vesFaultFields.setAlarmInterfaceA(alarmNotif.getFaultSource());
vesFaultFields.setEventCategory(VES_EVENT_CATEGORY);
- vesFaultFields.setEventSeverity(alarmNotif.getFaultSeverity().getName());
+ if (alarmNotif.getIsCleared()) {
+ vesFaultFields.setEventSeverity("NORMAL");
+ } else {
+ vesFaultFields.setEventSeverity(alarmNotif.getFaultSeverity().getName());
+ }
vesFaultFields.setEventSourceType(getModelName());
vesFaultFields.setFaultFieldsVersion(VES_FAULT_FIELDS_VERSION);
vesFaultFields.setSpecificProblem(alarmNotif.getFaultText());
diff --git a/sdnr/wt/devicemanager-o-ran-sc/o-ran/ru-fh/provider/src/test/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/oran/impl/TestAlarmNotif.java b/sdnr/wt/devicemanager-o-ran-sc/o-ran/ru-fh/provider/src/test/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/oran/impl/TestAlarmNotif.java
index b3388114b..4d10dd154 100644
--- a/sdnr/wt/devicemanager-o-ran-sc/o-ran/ru-fh/provider/src/test/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/oran/impl/TestAlarmNotif.java
+++ b/sdnr/wt/devicemanager-o-ran-sc/o-ran/ru-fh/provider/src/test/java/org/onap/ccsdk/features/sdnr/wt/devicemanager/oran/impl/TestAlarmNotif.java
@@ -83,8 +83,7 @@ public class TestAlarmNotif implements AlarmNotif {
@Override
public Boolean getIsCleared() {
- // TODO Auto-generated method stub
- return null;
+ return true;
}
}