/*
- * Copyright (c) 2013, 2015 Red Hat, Inc. and others. All rights reserved.
+ * Copyright (c) 2013, 2016 Red Hat, Inc. and others. All rights reserved.
*
* This program and the accompanying materials are made available under the
* terms of the Eclipse Public License v1.0 which accompanies this distribution,
import org.opendaylight.ovsdb.openstack.netvirt.api.EventDispatcher;
import org.opendaylight.ovsdb.openstack.netvirt.api.NodeCacheManager;
import org.opendaylight.ovsdb.openstack.netvirt.api.Southbound;
+import org.opendaylight.ovsdb.openstack.netvirt.impl.DistributedArpService;
import org.opendaylight.ovsdb.openstack.netvirt.impl.NeutronL3Adapter;
import org.opendaylight.ovsdb.utils.servicehelper.ServiceHelper;
import org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.ovsdb.rev150105.OvsdbTerminationPointAugmentation;
// The implementation for each of these services is resolved by the OSGi Service Manager
private volatile NodeCacheManager nodeCacheManager;
private volatile NeutronL3Adapter neutronL3Adapter;
+ private volatile DistributedArpService distributedArpService;
private volatile Southbound southbound;
/**
LOG.debug(" Port-ADD successful for tenant-id - {}, network-id - {}, port-id - {}",
neutronPort.getTenantID(), neutronPort.getNetworkUUID(),
neutronPort.getID());
+ distributedArpService.handlePortEvent(neutronPort, Action.ADD);
neutronL3Adapter.handleNeutronPortEvent(neutronPort, Action.ADD);
}
}
private void doNeutronPortUpdated(NeutronPort neutronPort) {
LOG.debug("Handling neutron update port {}", neutronPort);
+ distributedArpService.handlePortEvent(neutronPort, Action.UPDATE);
neutronL3Adapter.handleNeutronPortEvent(neutronPort, Action.UPDATE);
}
}
private void doNeutronPortDeleted(NeutronPort neutronPort) {
LOG.debug("Handling neutron delete port {}", neutronPort);
+ distributedArpService.handlePortEvent(neutronPort, Action.DELETE);
neutronL3Adapter.handleNeutronPortEvent(neutronPort, Action.DELETE);
//TODO: Need to implement getNodes
List<Node> nodes = nodeCacheManager.getNodes();
(NodeCacheManager) ServiceHelper.getGlobalInstance(NodeCacheManager.class, this);
neutronL3Adapter =
(NeutronL3Adapter) ServiceHelper.getGlobalInstance(NeutronL3Adapter.class, this);
+ distributedArpService =
+ (DistributedArpService) ServiceHelper.getGlobalInstance(DistributedArpService.class, this);
southbound =
(Southbound) ServiceHelper.getGlobalInstance(Southbound.class, this);
eventDispatcher =