aboutsummaryrefslogtreecommitdiffstats
path: root/kubernetes/pomba/charts/pomba-validation-service/resources/bundleconfig/etc
diff options
context:
space:
mode:
authorburdziak <olaf.burdziakowski@nokia.com>2019-05-24 15:36:15 +0200
committerburdziak <olaf.burdziakowski@nokia.com>2019-05-27 11:43:29 +0200
commiteafc9727053c3f4fefad69f324e74f5bd6ff57fd (patch)
tree574e6d75a608edaffaf209e8889a4ed1e932d9cc /kubernetes/pomba/charts/pomba-validation-service/resources/bundleconfig/etc
parentc89dd8b0e3f15a4aa56c4489349c56c6715e06bc (diff)
Make POMBA able to detect dummy notifications
Issue-ID: LOG-1056 Signed-off-by: burdziak <olaf.burdziakowski@nokia.com> Change-Id: I8bb81cdad651261063fd9d92b3c3a6b8f9346bf6
Diffstat (limited to 'kubernetes/pomba/charts/pomba-validation-service/resources/bundleconfig/etc')
-rw-r--r--kubernetes/pomba/charts/pomba-validation-service/resources/bundleconfig/etc/rules/poa-event/default-rules.groovy18
1 files changed, 18 insertions, 0 deletions
diff --git a/kubernetes/pomba/charts/pomba-validation-service/resources/bundleconfig/etc/rules/poa-event/default-rules.groovy b/kubernetes/pomba/charts/pomba-validation-service/resources/bundleconfig/etc/rules/poa-event/default-rules.groovy
index df75b31eab..4a7f30452f 100644
--- a/kubernetes/pomba/charts/pomba-validation-service/resources/bundleconfig/etc/rules/poa-event/default-rules.groovy
+++ b/kubernetes/pomba/charts/pomba-validation-service/resources/bundleconfig/etc/rules/poa-event/default-rules.groovy
@@ -218,10 +218,28 @@ entity {
name 'SDC-AAI-vf-module-instance-check'
attributes 'context-list.sdc.vnfList[*].vfModuleList[*]', 'context-list.aai.vnfList[*].vfModuleList[*]'
}
+
+ useRule {
+ name 'AAI-not-empty'
+ attributes 'context-list.aai.pnfList', 'context-list.aai.vnfList', 'context-list.aai.networkList'
+ }
}
}
rule {
+ name 'AAI-not-empty'
+ category 'VNFC Consistency'
+ description 'Check if AAI collected anything'
+ errorText 'AAI section is empty'
+ severity 'ERROR'
+ attributes 'pnfList', 'vnfList', 'networkList'
+ validate '''
+ // expect at least one not empty list
+ return !pnfList.isEmpty() || !vnfList.isEmpty() || !networkList.isEmpty()
+ '''
+}
+
+rule {
name 'SDC-AAI-vnfc-type'
category 'VNFC Consistency'
description 'Validate that each VNFC instance in AAI conforms to a VNFC type defined in SDC model'