import org.opendaylight.genius.infra.ManagedNewTransactionRunner;
import org.opendaylight.genius.infra.ManagedNewTransactionRunnerImpl;
import org.opendaylight.infrautils.utils.concurrent.Executors;
-import org.opendaylight.infrautils.utils.concurrent.ListenableFutures;
+import org.opendaylight.infrautils.utils.concurrent.LoggingFutures;
import org.opendaylight.mdsal.binding.api.DataBroker;
import org.opendaylight.mdsal.binding.api.ReadTransaction;
import org.opendaylight.mdsal.binding.api.ReadWriteTransaction;
LOG.info("Cloudscaler Deleting compute node details {}",
buildOpenflowNodeIid(computeNode));
LOG.info("Cloudscaler Deleting compute node details {}", buildOvsdbNodeId(computeNode));
- ListenableFutures.addErrorLogging(txRunner.callWithNewReadWriteTransactionAndSubmit(tx -> {
+ LoggingFutures.addErrorLogging(txRunner.callWithNewReadWriteTransactionAndSubmit(tx -> {
computeNodeManager.deleteComputeNode(tx, computeNode);
}), LOG, "Cloudscaler Failed to delete the compute node");
- ListenableFutures.addErrorLogging(txRunner.callWithNewReadWriteTransactionAndSubmit(tx -> {
+ LoggingFutures.addErrorLogging(txRunner.callWithNewReadWriteTransactionAndSubmit(tx -> {
tx.delete(LogicalDatastoreType.CONFIGURATION, buildOpenflowNodeIid(computeNode));
}), LOG, "Cloudscaler Failed to delete the config inventory");
- ListenableFutures.addErrorLogging(txRunner.callWithNewReadWriteTransactionAndSubmit(tx -> {
+ LoggingFutures.addErrorLogging(txRunner.callWithNewReadWriteTransactionAndSubmit(tx -> {
tx.delete(LogicalDatastoreType.CONFIGURATION, buildOvsdbNodeId(computeNode));
}), LOG, "Cloudscaler Failed to delete the config topology");
}
.child(TransportZone.class, zone.key())
.child(Vteps.class, vteps.key());
LOG.error("Cloudscaler deleting dpn {}", vteps);
- ListenableFutures.addErrorLogging(
+ LoggingFutures.addErrorLogging(
txRunner.callWithNewReadWriteTransactionAndSubmit(tx -> {
tx.delete(LogicalDatastoreType.CONFIGURATION, dpnVtepIid);
}), LOG, "Cloudscaler Failed to delete the itm tep");
import org.opendaylight.genius.mdsalutil.ActionInfo;
import org.opendaylight.infrautils.diagstatus.ServiceState;
import org.opendaylight.infrautils.jobcoordinator.JobCoordinator;
-import org.opendaylight.infrautils.utils.concurrent.ListenableFutures;
+import org.opendaylight.infrautils.utils.concurrent.LoggingFutures;
import org.opendaylight.mdsal.binding.api.DataBroker;
import org.opendaylight.mdsal.binding.api.ReadTransaction;
import org.opendaylight.mdsal.common.api.LogicalDatastoreType;
.getInterfaceIdentifier(new InterfaceKey(interfaceName));
ListenableFuture<Void> future = txRunner.callWithNewWriteOnlyTransactionAndSubmit(CONFIGURATION,
tx -> tx.mergeParentStructurePut(interfaceIId, interfaceBuilder.build()));
- ListenableFutures.addErrorLogging(future, LOG, "Failed to (async) write {}", interfaceIId);
+ LoggingFutures.addErrorLogging(future, LOG, "Failed to (async) write {}", interfaceIId);
return future;
}
public void bindService(String interfaceName, Class<? extends ServiceModeBase> serviceMode,
BoundServices serviceInfo, TypedWriteTransaction<Configuration> tx) {
if (tx == null) {
- ListenableFutures.addErrorLogging(txRunner.callWithNewWriteOnlyTransactionAndSubmit(CONFIGURATION,
+ LoggingFutures.addErrorLogging(txRunner.callWithNewWriteOnlyTransactionAndSubmit(CONFIGURATION,
wtx -> IfmUtil.bindService(wtx, interfaceName, serviceInfo, serviceMode)), LOG,
"Error binding the InterfacemgrProvider service");
} else {
import org.opendaylight.genius.infra.ManagedNewTransactionRunnerImpl;
import org.opendaylight.genius.infra.TypedReadTransaction;
import org.opendaylight.genius.infra.TypedReadWriteTransaction;
-import org.opendaylight.infrautils.utils.concurrent.ListenableFutures;
+import org.opendaylight.infrautils.utils.concurrent.LoggingFutures;
import org.opendaylight.mdsal.binding.api.DataBroker;
import org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.interfaces.rev140508.interfaces.Interface;
import org.opendaylight.yang.gen.v1.urn.opendaylight.genius.alivenessmonitor.rev160411.AlivenessMonitorService;
RpcResult<MonitorStartOutput> rpcResult = result.get();
if (rpcResult.isSuccessful()) {
long monitorId = rpcResult.getResult().getMonitorId().toJava();
- ListenableFutures.addErrorLogging(
+ LoggingFutures.addErrorLogging(
txRunner.callWithNewReadWriteTransactionAndSubmit(OPERATIONAL, tx -> {
createOrUpdateInterfaceMonitorIdMap(tx, trunkInterfaceName, monitorId);
createOrUpdateMonitorIdInterfaceMap(tx, trunkInterfaceName, monitorId);
return;
}
LOG.debug("stop LLDP monitoring for {}", trunkInterface);
- ListenableFutures.addErrorLogging(txRunner.callWithNewReadWriteTransactionAndSubmit(OPERATIONAL, tx -> {
+ LoggingFutures.addErrorLogging(txRunner.callWithNewReadWriteTransactionAndSubmit(OPERATIONAL, tx -> {
List<Uint32> monitorIds = getMonitorIdForInterface(tx, trunkInterface);
if (monitorIds == null) {
LOG.error("Monitor Id doesn't exist for Interface {}", trunkInterface);
MonitorStopInput input = new MonitorStopInputBuilder().setMonitorId(monitorId).build();
ListenableFuture<RpcResult<MonitorStopOutput>> future = alivenessMonitorService.monitorStop(input);
- ListenableFutures.addErrorLogging(future, LOG, "Stop LLDP monitoring for {}", trunkInterface);
+ LoggingFutures.addErrorLogging(future, LOG, "Stop LLDP monitoring for {}", trunkInterface);
removeMonitorIdInterfaceMap(tx, monitorId);
removeMonitorIdFromInterfaceMonitorIdMap(tx, interfaceName, monitorId);
ListenableFuture<RpcResult<MonitorProfileDeleteOutput>> future =
alivenessMonitorService.monitorProfileDelete(profileDeleteInput);
- ListenableFutures.addErrorLogging(future, LOG, "Delete monitor profile {}", interfaceName);
+ LoggingFutures.addErrorLogging(future, LOG, "Delete monitor profile {}", interfaceName);
}
}
}
* terms of the Eclipse Public License v1.0 which accompanies this distribution,
* and is available at http://www.eclipse.org/legal/epl-v10.html
*/
-
package org.opendaylight.genius.interfacemanager.listeners;
import static org.opendaylight.genius.infra.Datastore.OPERATIONAL;
import org.opendaylight.genius.infra.ManagedNewTransactionRunnerImpl;
import org.opendaylight.genius.interfacemanager.commons.AlivenessMonitorUtils;
import org.opendaylight.genius.interfacemanager.commons.InterfaceManagerCommonUtils;
-import org.opendaylight.infrautils.utils.concurrent.ListenableFutures;
+import org.opendaylight.infrautils.utils.concurrent.LoggingFutures;
import org.opendaylight.mdsal.binding.api.DataBroker;
import org.opendaylight.mdsal.binding.api.NotificationService;
import org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.interfaces.rev140508.interfaces.state.Interface.OperStatus;
@Override
public void onMonitorEvent(MonitorEvent notification) {
- ListenableFutures.addErrorLogging(txRunner.callWithNewReadWriteTransactionAndSubmit(OPERATIONAL, tx -> {
+ LoggingFutures.addErrorLogging(txRunner.callWithNewReadWriteTransactionAndSubmit(OPERATIONAL, tx -> {
Uint32 monitorId = notification.getEventData().getMonitorId();
String tunnelInterface = AlivenessMonitorUtils.getInterfaceFromMonitorId(tx, monitorId);
if (tunnelInterface == null) {
* terms of the Eclipse Public License v1.0 which accompanies this distribution,
* and is available at http://www.eclipse.org/legal/epl-v10.html
*/
-
package org.opendaylight.genius.ipv6util.nd;
import java.net.InetAddress;
import org.opendaylight.genius.mdsalutil.NwConstants;
import org.opendaylight.genius.mdsalutil.actions.ActionGroup;
import org.opendaylight.genius.mdsalutil.packet.IPProtocols;
-import org.opendaylight.infrautils.utils.concurrent.ListenableFutures;
+import org.opendaylight.infrautils.utils.concurrent.LoggingFutures;
import org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.inet.types.rev130715.Ipv6Address;
import org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.yang.types.rev130715.MacAddress;
import org.opendaylight.yang.gen.v1.urn.opendaylight.genius.ipv6.nd.packet.rev160620.NeighborSolicitationPacket;
// Tx the packet out of the controller.
LOG.debug("Transmitting the Neighbor Solicitation packet out on {}", dpnId);
- ListenableFutures.addErrorLogging(packetService.transmitPacket(input), LOG, "transmitPacket");
+ LoggingFutures.addErrorLogging(packetService.transmitPacket(input), LOG, "transmitPacket");
return true;
}
"Transmitting Neighbor Solicitation packet out. srcMacAddress={}, srcIpv6Address={}, "
+ "targetIpv6Address={}, dpId={}, ofGroupId={}",
srcMacAddress.getValue(), srcIpv6Address.getValue(), targetIpv6Address.getValue(), dpId, ofGroupId);
- ListenableFutures.addErrorLogging(packetService.transmitPacket(input), LOG, "transmitPacket");
+ LoggingFutures.addErrorLogging(packetService.transmitPacket(input), LOG, "transmitPacket");
}
}