aboutsummaryrefslogtreecommitdiffstats
path: root/vnfs/vLBMS/apis
diff options
context:
space:
mode:
authorMarco Platania <platania@research.att.com>2018-03-21 17:44:27 -0400
committerMarco Platania <platania@research.att.com>2018-03-21 17:44:27 -0400
commit13fdadba0a69e43fcfbd55cf4f473cc0db612640 (patch)
tree98d97a31cb6fe5517a2186a0fbc299643eeb6ff8 /vnfs/vLBMS/apis
parentc18a8faa269799bfe5eaddbb431aff86de689104 (diff)
Fix health check issues with vLBMS
- Allow vLB to run health check only against active vDNS instances - Change the path to status file - Make run_health scripts executable Change-Id: I6909d8507cafee5f9e93fcceb868db5d4f224045 Issue-ID: INT-433 Signed-off-by: Marco Platania <platania@research.att.com>
Diffstat (limited to 'vnfs/vLBMS/apis')
-rw-r--r--vnfs/vLBMS/apis/health-vnf-onap-plugin/health-vnf-onap-plugin-impl/src/main/java/org/onap/vnf/health/read/ElementStateCustomizer.java9
1 files changed, 6 insertions, 3 deletions
diff --git a/vnfs/vLBMS/apis/health-vnf-onap-plugin/health-vnf-onap-plugin-impl/src/main/java/org/onap/vnf/health/read/ElementStateCustomizer.java b/vnfs/vLBMS/apis/health-vnf-onap-plugin/health-vnf-onap-plugin-impl/src/main/java/org/onap/vnf/health/read/ElementStateCustomizer.java
index 15d0c22a..b83ccef6 100644
--- a/vnfs/vLBMS/apis/health-vnf-onap-plugin/health-vnf-onap-plugin-impl/src/main/java/org/onap/vnf/health/read/ElementStateCustomizer.java
+++ b/vnfs/vLBMS/apis/health-vnf-onap-plugin/health-vnf-onap-plugin-impl/src/main/java/org/onap/vnf/health/read/ElementStateCustomizer.java
@@ -168,9 +168,12 @@ public final class ElementStateCustomizer implements InitializingReaderCustomize
// check all the vDNS instances
Map<String, VdnsInstance> activeVdnsInstances = dnsInstanceManager.getDnsInstancesAsMap();
Iterator<String> iter = activeVdnsInstances.keySet().iterator();
- while(iter.hasNext()){
- if(!getRemoteVnfcHealthStatus(activeVdnsInstances.get(iter.next()).getOamIpAddr())) {
- healthStatus = "unhealthy";
+ while(iter.hasNext()) {
+ VdnsInstance vdns = activeVdnsInstances.get(iter.next());
+ if(vdns.isEnabled()) {
+ if(!getRemoteVnfcHealthStatus(vdns.getOamIpAddr())) {
+ healthStatus = "unhealthy";
+ }
}
}
}