diff options
author | 2018-03-20 17:09:13 -0400 | |
---|---|---|
committer | 2018-03-20 17:09:13 -0400 | |
commit | dbdb9d7c44a0aa7ce56e5d0b0447e12a1fce9102 (patch) | |
tree | 88b1885118c4e7d42fa9d597646e3dc561c111de /vnfs/vLBMS/apis/vlb-business-vnf-onap-plugin/vlb-business-vnf-onap-plugin-impl/src/main/java/org/onap/vnf/vlb/write/ElementCustomizer.java | |
parent | 6c95e2550149ef09ec481c282404e693d91595fe (diff) |
Allow vLB to check multiple vDNSs
Modify the health check plugin to allow the vLB to run health check against multiple vDNS instances
Change-Id: Ia0d577750378f5c7631be88be85b42d090a71289
Issue-ID: INT-433
Signed-off-by: Marco Platania <platania@research.att.com>
Diffstat (limited to 'vnfs/vLBMS/apis/vlb-business-vnf-onap-plugin/vlb-business-vnf-onap-plugin-impl/src/main/java/org/onap/vnf/vlb/write/ElementCustomizer.java')
-rw-r--r-- | vnfs/vLBMS/apis/vlb-business-vnf-onap-plugin/vlb-business-vnf-onap-plugin-impl/src/main/java/org/onap/vnf/vlb/write/ElementCustomizer.java | 13 |
1 files changed, 7 insertions, 6 deletions
diff --git a/vnfs/vLBMS/apis/vlb-business-vnf-onap-plugin/vlb-business-vnf-onap-plugin-impl/src/main/java/org/onap/vnf/vlb/write/ElementCustomizer.java b/vnfs/vLBMS/apis/vlb-business-vnf-onap-plugin/vlb-business-vnf-onap-plugin-impl/src/main/java/org/onap/vnf/vlb/write/ElementCustomizer.java index d8da0b5b..10457a60 100644 --- a/vnfs/vLBMS/apis/vlb-business-vnf-onap-plugin/vlb-business-vnf-onap-plugin-impl/src/main/java/org/onap/vnf/vlb/write/ElementCustomizer.java +++ b/vnfs/vLBMS/apis/vlb-business-vnf-onap-plugin/vlb-business-vnf-onap-plugin-impl/src/main/java/org/onap/vnf/vlb/write/ElementCustomizer.java @@ -14,6 +14,10 @@ * limitations under the License. */ + /* + * Modifications copyright (c) 2018 AT&T Intellectual Property + */ + package org.onap.vnf.vlb.write; import org.onap.vnf.vlb.CrudService; @@ -24,8 +28,6 @@ import javax.annotation.Nonnull; import org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.vlb.business.vnf.onap.plugin.rev160918.vlb.business.vnf.onap.plugin.params.vdns.instances.VdnsInstance; import org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.vlb.business.vnf.onap.plugin.rev160918.vlb.business.vnf.onap.plugin.params.vdns.instances.VdnsInstanceKey; import org.opendaylight.yangtools.yang.binding.InstanceIdentifier; -import org.slf4j.Logger; -import org.slf4j.LoggerFactory; /** * Writer for {@link Element} list node from our YANG model. @@ -34,11 +36,10 @@ public final class ElementCustomizer implements ListWriterCustomizer<VdnsInstanc private final CrudService<VdnsInstance> crudService; private DnsInstanceManager dnsInstanceManager; - private static final Logger LOG = LoggerFactory.getLogger(ElementCustomizer.class); public ElementCustomizer(@Nonnull final CrudService<VdnsInstance> crudService) { this.crudService = crudService; - dnsInstanceManager = new DnsInstanceManager(); + dnsInstanceManager = DnsInstanceManager.getInstance(); } @Override @@ -47,7 +48,7 @@ public final class ElementCustomizer implements ListWriterCustomizer<VdnsInstanc //perform write of data,or throw exception //invoked by PUT operation,if provided data doesn't exist in Config data crudService.writeData(id, dataAfter); - dnsInstanceManager.addDnsInstance(dataAfter.getIpAddr(), dataAfter.isIsEnabled()); + dnsInstanceManager.addDnsInstance(dataAfter.getIpAddr(), dataAfter); } @Override @@ -58,7 +59,7 @@ public final class ElementCustomizer implements ListWriterCustomizer<VdnsInstanc //perform update of data,or throw exception //invoked by PUT operation,if provided data does exist in Config data crudService.updateData(id, dataBefore, dataAfter); - dnsInstanceManager.updateDnsInstance(dataAfter.getIpAddr(), dataAfter.isIsEnabled()); + dnsInstanceManager.updateDnsInstance(dataAfter.getIpAddr(), dataAfter); } @Override |