X-Git-Url: https://git.opendaylight.org/gerrit/gitweb?p=controller.git;a=blobdiff_plain;f=opendaylight%2Fnetworkconfiguration%2Fneutron%2Fnorthbound%2Fsrc%2Fmain%2Fjava%2Forg%2Fopendaylight%2Fcontroller%2Fnetworkconfig%2Fneutron%2Fnorthbound%2FNeutronLoadBalancerHealthMonitorNorthbound.java;h=85aba5d69080d29e1d596303af0b909a2a751ea4;hp=6cd2673ff80e09569284b61024e28906130a9a2b;hb=b1ad203b32b73fc06a856cdfae243986c8037617;hpb=5355c84eec599e751411e9e6a43e2be6e92f77d6 diff --git a/opendaylight/networkconfiguration/neutron/northbound/src/main/java/org/opendaylight/controller/networkconfig/neutron/northbound/NeutronLoadBalancerHealthMonitorNorthbound.java b/opendaylight/networkconfiguration/neutron/northbound/src/main/java/org/opendaylight/controller/networkconfig/neutron/northbound/NeutronLoadBalancerHealthMonitorNorthbound.java index 6cd2673ff8..85aba5d690 100644 --- a/opendaylight/networkconfiguration/neutron/northbound/src/main/java/org/opendaylight/controller/networkconfig/neutron/northbound/NeutronLoadBalancerHealthMonitorNorthbound.java +++ b/opendaylight/networkconfiguration/neutron/northbound/src/main/java/org/opendaylight/controller/networkconfig/neutron/northbound/NeutronLoadBalancerHealthMonitorNorthbound.java @@ -9,20 +9,10 @@ package org.opendaylight.controller.networkconfig.neutron.northbound; -import org.codehaus.enunciate.jaxrs.ResponseCode; -import org.codehaus.enunciate.jaxrs.StatusCodes; -import org.opendaylight.controller.networkconfig.neutron.INeutronLoadBalancerHealthMonitorAware; -import org.opendaylight.controller.networkconfig.neutron.INeutronLoadBalancerHealthMonitorCRUD; -import org.opendaylight.controller.networkconfig.neutron.NeutronCRUDInterfaces; -import org.opendaylight.controller.networkconfig.neutron.NeutronLoadBalancer; -import org.opendaylight.controller.networkconfig.neutron.NeutronLoadBalancerHealthMonitor; -import org.opendaylight.controller.northbound.commons.RestMessages; -import org.opendaylight.controller.northbound.commons.exception.BadRequestException; -import org.opendaylight.controller.northbound.commons.exception.ResourceNotFoundException; -import org.opendaylight.controller.northbound.commons.exception.ServiceUnavailableException; -import org.opendaylight.controller.sal.utils.ServiceHelper; -import org.slf4j.Logger; -import org.slf4j.LoggerFactory; +import java.util.ArrayList; +import java.util.HashMap; +import java.util.Iterator; +import java.util.List; import javax.ws.rs.Consumes; import javax.ws.rs.DELETE; @@ -35,10 +25,16 @@ import javax.ws.rs.Produces; import javax.ws.rs.QueryParam; import javax.ws.rs.core.MediaType; import javax.ws.rs.core.Response; -import java.util.ArrayList; -import java.util.HashMap; -import java.util.Iterator; -import java.util.List; + +import org.codehaus.enunciate.jaxrs.ResponseCode; +import org.codehaus.enunciate.jaxrs.StatusCodes; +import org.opendaylight.controller.networkconfig.neutron.INeutronLoadBalancerHealthMonitorAware; +import org.opendaylight.controller.networkconfig.neutron.INeutronLoadBalancerHealthMonitorCRUD; +import org.opendaylight.controller.networkconfig.neutron.NeutronCRUDInterfaces; +import org.opendaylight.controller.networkconfig.neutron.NeutronLoadBalancer; +import org.opendaylight.controller.networkconfig.neutron.NeutronLoadBalancerHealthMonitor; +import org.slf4j.Logger; +import org.slf4j.LoggerFactory; /** * Neutron Northbound REST APIs for Load Balancer HealthMonitor.
@@ -212,7 +208,7 @@ public class NeutronLoadBalancerHealthMonitorNorthbound { } loadBalancerHealthMonitorInterface.addNeutronLoadBalancerHealthMonitor(singleton); - Object[] instances = ServiceHelper.getGlobalInstances(INeutronLoadBalancerHealthMonitorAware.class, this, null); + Object[] instances = NeutronUtil.getInstances(INeutronLoadBalancerHealthMonitorAware.class, this); if (instances != null) { for (Object instance : instances) { INeutronLoadBalancerHealthMonitorAware service = (INeutronLoadBalancerHealthMonitorAware) instance; @@ -233,7 +229,7 @@ public class NeutronLoadBalancerHealthMonitorNorthbound { List bulk = input.getBulk(); Iterator i = bulk.iterator(); HashMap testMap = new HashMap(); - Object[] instances = ServiceHelper.getGlobalInstances(INeutronLoadBalancerHealthMonitorAware.class, this, null); + Object[] instances = NeutronUtil.getInstances(INeutronLoadBalancerHealthMonitorAware.class, this); while (i.hasNext()) { NeutronLoadBalancerHealthMonitor test = i.next(); @@ -330,7 +326,7 @@ public class NeutronLoadBalancerHealthMonitorNorthbound { throw new BadRequestException("Attribute edit blocked by Neutron"); } - Object[] instances = ServiceHelper.getGlobalInstances(INeutronLoadBalancerHealthMonitorAware.class, this, null); + Object[] instances = NeutronUtil.getInstances(INeutronLoadBalancerHealthMonitorAware.class, this); if (instances != null) { for (Object instance : instances) { INeutronLoadBalancerHealthMonitorAware service = (INeutronLoadBalancerHealthMonitorAware) instance; @@ -388,7 +384,7 @@ public class NeutronLoadBalancerHealthMonitorNorthbound { return Response.status(409).build(); } NeutronLoadBalancerHealthMonitor singleton = loadBalancerHealthMonitorInterface.getNeutronLoadBalancerHealthMonitor(loadBalancerHealthMonitorID); - Object[] instances = ServiceHelper.getGlobalInstances(INeutronLoadBalancerHealthMonitorAware.class, this, null); + Object[] instances = NeutronUtil.getInstances(INeutronLoadBalancerHealthMonitorAware.class, this); if (instances != null) { for (Object instance : instances) { INeutronLoadBalancerHealthMonitorAware service = (INeutronLoadBalancerHealthMonitorAware) instance;