Merge "Add LOG.isDebugEnabled to add performance." into stable/boron
authorJozef Bacigal <jozef.bacigal@pantheon.tech>
Tue, 20 Dec 2016 13:49:21 +0000 (13:49 +0000)
committerGerrit Code Review <gerrit@opendaylight.org>
Tue, 20 Dec 2016 13:49:21 +0000 (13:49 +0000)
openflowplugin-impl/src/main/java/org/opendaylight/openflowplugin/impl/statistics/StatisticsGatheringUtils.java
openflowplugin-impl/src/test/java/org/opendaylight/openflowplugin/impl/statistics/StatisticsGatheringUtilsTest.java

index 8a47762e07ca22566a212a5bc0db3ed1237a4dd0..3893b9f391ef6ccef71bff37be4aa56fbd742a1a 100644 (file)
@@ -170,7 +170,10 @@ public final class StatisticsGatheringUtils {
             public ListenableFuture<Boolean> apply(final RpcResult<List<MultipartReply>> rpcResult) {
                 boolean isMultipartProcessed = Boolean.TRUE;
                 if (rpcResult.isSuccessful()) {
-                    LOG.debug("Stats reply successfully received for node {} of type {}", deviceInfo.getNodeId(), type);
+                    if (LOG.isDebugEnabled()) {
+                        LOG.debug("Stats reply successfully received for node {} of type {}",
+                                deviceInfo.getNodeId(), type);
+                    }
 
                     // TODO: in case the result value is null then multipart data probably got processed on the fly -
                     // TODO: this contract should by clearly stated and enforced - now simple true value is returned
@@ -187,8 +190,8 @@ public final class StatisticsGatheringUtils {
                                 multipartData = multipartDataList.get(0);
                                 allMultipartData = Iterables.concat(allMultipartData, multipartDataList);
                             }
-                        } catch (final Exception e) {
-                            LOG.warn("stats processing of type {} for node {} failed during transfomation step",
+                        } catch (final TransactionChainClosedException e) {
+                            LOG.warn("stats processing of type {} for node {} failed during transformation step",
                                     type, deviceInfo.getNodeId(), e);
                             return Futures.immediateFailedFuture(e);
                         }
@@ -247,24 +250,30 @@ public final class StatisticsGatheringUtils {
                             } else {
                                 isMultipartProcessed = Boolean.FALSE;
                             }
-                        } catch (final Exception e) {
+                        } catch (final TransactionChainClosedException e) {
                             LOG.warn("stats processing of type {} for node {} failed during write-to-tx step",
                                     type, deviceInfo.getNodeId(), e);
                             return Futures.immediateFailedFuture(e);
                         }
 
-                        LOG.debug("Stats reply added to transaction for node {} of type {}",
-                                deviceInfo.getNodeId(), type);
+                        if (LOG.isDebugEnabled()) {
+                            LOG.debug("Stats reply added to transaction for node {} of type {}",
+                                    deviceInfo.getNodeId(), type);
+                        }
 
                         //TODO : implement experimenter
                     } else {
-                        LOG.debug("Stats reply was empty for node {} of type {}",
-                                deviceInfo.getNodeId(), type);
+                        if (LOG.isDebugEnabled()) {
+                            LOG.debug("Stats reply was empty for node {} of type {}",
+                                    deviceInfo.getNodeId(), type);
+                        }
                     }
 
                 } else {
-                    LOG.debug("Stats reply FAILED for node {} of type {}: {}",
-                            deviceInfo.getNodeId(), type, rpcResult.getErrors());
+                    if (LOG.isDebugEnabled()) {
+                        LOG.debug("Stats reply FAILED for node {} of type {}: {}",
+                                deviceInfo.getNodeId(), type, rpcResult.getErrors());
+                    }
                     isMultipartProcessed = Boolean.FALSE;
                 }
                 return Futures.immediateFuture(isMultipartProcessed);
@@ -275,7 +284,8 @@ public final class StatisticsGatheringUtils {
     private static void processMeterConfigStatsUpdated(final Iterable<MeterConfigStatsUpdated> data,
                                                        final DeviceInfo deviceInfo,
                                                        final TxFacade txFacade,
-                                                       final DeviceMeterRegistry meterRegistry) throws Exception {
+                                                       final DeviceMeterRegistry meterRegistry)
+            throws TransactionChainClosedException {
         final InstanceIdentifier<FlowCapableNode> fNodeIdent = assembleFlowCapableNodeInstanceIdentifier(deviceInfo);
         deleteAllKnownMeters(meterRegistry, fNodeIdent, txFacade);
         for (final MeterConfigStatsUpdated meterConfigStatsUpdated : data) {
@@ -306,15 +316,11 @@ public final class StatisticsGatheringUtils {
         final ListenableFuture<Void> deleteFuture
                 = initial ? Futures.immediateFuture(null) : deleteAllKnownFlows(deviceInfo,
                 flowRegistry, txFacade);
-        return Futures.transform(deleteFuture, new Function<Void, Boolean>() {
-
-            @Override
-            public Boolean apply(final Void input) {
-                writeFlowStatistics(data, deviceInfo, flowRegistry, txFacade);
-                txFacade.submitTransaction();
-                EventsTimeCounter.markEnd(eventIdentifier);
-                return Boolean.TRUE;
-            }
+        return Futures.transform(deleteFuture, (Function<Void, Boolean>) input -> {
+            writeFlowStatistics(data, deviceInfo, flowRegistry, txFacade);
+            txFacade.submitTransaction();
+            EventsTimeCounter.markEnd(eventIdentifier);
+            return Boolean.TRUE;
         });
     }
 
@@ -343,7 +349,7 @@ public final class StatisticsGatheringUtils {
                     txFacade.writeToTransaction(LogicalDatastoreType.OPERATIONAL, flowIdent, flowBuilder.build());
                 }
             }
-        } catch (Exception e) {
+        } catch (TransactionChainClosedException e) {
             LOG.warn("Not able to write to transaction: {}", e.getMessage());
         }
     }
@@ -397,7 +403,7 @@ public final class StatisticsGatheringUtils {
     private static void processQueueStatistics(
             final Iterable<QueueStatisticsUpdate> data,
             final DeviceInfo deviceInfo,
-            final TxFacade txFacade) throws Exception {
+            final TxFacade txFacade) throws TransactionChainClosedException {
         // TODO: clean all queues of all node-connectors before writing up-to-date stats
         final InstanceIdentifier<Node> nodeIdent = deviceInfo.getNodeInstanceIdentifier();
         for (final QueueStatisticsUpdate queueStatisticsUpdate : data) {
@@ -429,7 +435,7 @@ public final class StatisticsGatheringUtils {
     private static void processFlowTableStatistics(
             final Iterable<FlowTableStatisticsUpdate> data,
             final DeviceInfo deviceInfo,
-            final TxFacade txFacade) throws Exception {
+            final TxFacade txFacade) throws TransactionChainClosedException {
         final InstanceIdentifier<FlowCapableNode> fNodeIdent = assembleFlowCapableNodeInstanceIdentifier(deviceInfo);
         for (final FlowTableStatisticsUpdate flowTableStatisticsUpdate : data) {
 
@@ -447,7 +453,7 @@ public final class StatisticsGatheringUtils {
     private static void processNodeConnectorStatistics(
             final Iterable<NodeConnectorStatisticsUpdate> data,
             final DeviceInfo deviceInfo,
-            final TxFacade txFacade) throws Exception {
+            final TxFacade txFacade) throws TransactionChainClosedException {
         final InstanceIdentifier<Node> nodeIdent = deviceInfo.getNodeInstanceIdentifier();
         for (final NodeConnectorStatisticsUpdate nodeConnectorStatisticsUpdate : data) {
             for (final NodeConnectorStatisticsAndPortNumberMap nodeConnectPort :
@@ -468,7 +474,7 @@ public final class StatisticsGatheringUtils {
 
     private static void processMetersStatistics(final Iterable<MeterStatisticsUpdated> data,
                                                 final DeviceInfo deviceInfo,
-                                                final TxFacade txFacade) throws Exception {
+                                                final TxFacade txFacade) throws TransactionChainClosedException {
         final InstanceIdentifier<FlowCapableNode> fNodeIdent = assembleFlowCapableNodeInstanceIdentifier(deviceInfo);
         for (final MeterStatisticsUpdated meterStatisticsUpdated : data) {
             for (final MeterStats meterStats : meterStatisticsUpdated.getMeterStats()) {
@@ -487,7 +493,7 @@ public final class StatisticsGatheringUtils {
     private static void deleteAllKnownMeters(
             final DeviceMeterRegistry meterRegistry,
             final InstanceIdentifier<FlowCapableNode> flowNodeIdent,
-            final TxFacade txFacade) throws Exception {
+            final TxFacade txFacade) throws TransactionChainClosedException {
         for (final MeterId meterId : meterRegistry.getAllMeterIds()) {
             final InstanceIdentifier<Meter> meterIdent = flowNodeIdent.child(Meter.class, new MeterKey(meterId));
             txFacade.addDeleteToTxChain(LogicalDatastoreType.OPERATIONAL, meterIdent);
@@ -499,7 +505,7 @@ public final class StatisticsGatheringUtils {
             final Iterable<GroupDescStatsUpdated> data,
             final DeviceInfo deviceInfo,
             final TxFacade txFacade,
-            final DeviceGroupRegistry groupRegistry) throws Exception {
+            final DeviceGroupRegistry groupRegistry) throws TransactionChainClosedException {
         final InstanceIdentifier<FlowCapableNode> fNodeIdent = assembleFlowCapableNodeInstanceIdentifier(deviceInfo);
         deleteAllKnownGroups(txFacade, fNodeIdent, groupRegistry);
 
@@ -523,7 +529,7 @@ public final class StatisticsGatheringUtils {
     private static void deleteAllKnownGroups(
             final TxFacade txFacade,
             final InstanceIdentifier<FlowCapableNode> flowNodeIdent,
-            final DeviceGroupRegistry groupRegistry) throws Exception {
+            final DeviceGroupRegistry groupRegistry) throws TransactionChainClosedException {
         for (final GroupId groupId : groupRegistry.getAllGroupIds()) {
             final InstanceIdentifier<Group> groupIdent = flowNodeIdent.child(Group.class, new GroupKey(groupId));
             txFacade.addDeleteToTxChain(LogicalDatastoreType.OPERATIONAL, groupIdent);
@@ -534,7 +540,7 @@ public final class StatisticsGatheringUtils {
     private static void processGroupStatistics(
             final Iterable<GroupStatisticsUpdated> data,
             final DeviceInfo deviceInfo,
-            final TxFacade txFacade) throws Exception {
+            final TxFacade txFacade) throws TransactionChainClosedException {
         final InstanceIdentifier<FlowCapableNode> fNodeIdent = assembleFlowCapableNodeInstanceIdentifier(deviceInfo);
         for (final GroupStatisticsUpdated groupStatistics : data) {
             for (final GroupStats groupStats : groupStatistics.getGroupStats()) {
index e6d11dae1126f73fd7bc725ea531ee72e6451fbc..607adc0627f987e3e48bf13263afb612886915a5 100644 (file)
@@ -48,7 +48,6 @@ import org.opendaylight.openflowplugin.api.openflow.registry.group.DeviceGroupRe
 import org.opendaylight.openflowplugin.api.openflow.registry.meter.DeviceMeterRegistry;
 import org.opendaylight.openflowplugin.api.openflow.statistics.ofpspecific.EventIdentifier;
 import org.opendaylight.openflowplugin.api.openflow.statistics.ofpspecific.StatisticsGatherer;
-import org.opendaylight.openflowplugin.impl.registry.flow.FlowRegistryKeyFactory;
 import org.opendaylight.openflowplugin.openflow.md.core.sal.convertor.ConvertorManager;
 import org.opendaylight.openflowplugin.openflow.md.core.sal.convertor.ConvertorManagerFactory;
 import org.opendaylight.yang.gen.v1.urn.opendaylight.flow.inventory.rev130819.FlowCapableNode;
@@ -249,7 +248,8 @@ public class StatisticsGatheringUtilsTest {
         fireAndCheck(type, statsData);
 
         final InstanceIdentifier<GroupStatistics> groupPath = dummyNodePath.augmentation(FlowCapableNode.class)
-                .child(Group.class, new GroupKey(new org.opendaylight.yang.gen.v1.urn.opendaylight.group.types.rev131018.GroupId(groupIdValue)))
+                .child(Group.class, new GroupKey(
+                        new org.opendaylight.yang.gen.v1.urn.opendaylight.group.types.rev131018.GroupId(groupIdValue)))
                 .augmentation(NodeGroupStatistics.class)
                 .child(GroupStatistics.class);
         verify(txFacade).writeToTransaction(Matchers.eq(LogicalDatastoreType.OPERATIONAL),
@@ -277,10 +277,13 @@ public class StatisticsGatheringUtilsTest {
 
         fireAndCheck(type, statsData);
 
-        final org.opendaylight.yang.gen.v1.urn.opendaylight.group.types.rev131018.GroupId storedGroupId = new org.opendaylight.yang.gen.v1.urn.opendaylight.group.types.rev131018.GroupId(groupIdValue);
-        final KeyedInstanceIdentifier<Group, GroupKey> groupPath = dummyNodePath.augmentation(FlowCapableNode.class).child(Group.class, new GroupKey(storedGroupId));
+        final org.opendaylight.yang.gen.v1.urn.opendaylight.group.types.rev131018.GroupId storedGroupId
+                = new org.opendaylight.yang.gen.v1.urn.opendaylight.group.types.rev131018.GroupId(groupIdValue);
+        final KeyedInstanceIdentifier<Group, GroupKey> groupPath
+                = dummyNodePath.augmentation(FlowCapableNode.class).child(Group.class, new GroupKey(storedGroupId));
 
-        verify(deviceContext, Mockito.never()).addDeleteToTxChain(Matchers.eq(LogicalDatastoreType.OPERATIONAL), Matchers.<InstanceIdentifier<?>> any());
+        verify(deviceContext, Mockito.never()).addDeleteToTxChain(
+                Matchers.eq(LogicalDatastoreType.OPERATIONAL), Matchers.<InstanceIdentifier<?>>any());
         verify(deviceGroupRegistry).removeMarked();
         verify(deviceGroupRegistry).store(storedGroupId);
         verify(txFacade).writeToTransaction(
@@ -314,7 +317,8 @@ public class StatisticsGatheringUtilsTest {
         fireAndCheck(type, statsData);
 
         final InstanceIdentifier<MeterStatistics> meterPath = dummyNodePath.augmentation(FlowCapableNode.class)
-                .child(Meter.class, new MeterKey(new org.opendaylight.yang.gen.v1.urn.opendaylight.meter.types.rev130918.MeterId(meterIdValue)))
+                .child(Meter.class, new MeterKey(
+                        new org.opendaylight.yang.gen.v1.urn.opendaylight.meter.types.rev130918.MeterId(meterIdValue)))
                 .augmentation(NodeMeterStatistics.class)
                 .child(MeterStatistics.class);
         verify(txFacade).writeToTransaction(Matchers.eq(LogicalDatastoreType.OPERATIONAL),
@@ -338,7 +342,8 @@ public class StatisticsGatheringUtilsTest {
         fireAndCheck(type, statsData);
 
         final InstanceIdentifier<FlowCapableNodeConnectorStatistics> portPath = dummyNodePath
-                .child(NodeConnector.class, new NodeConnectorKey(new NodeConnectorId("openflow:" + DUMMY_NODE_ID_VALUE + ":11")))
+                .child(NodeConnector.class, new NodeConnectorKey(
+                        new NodeConnectorId("openflow:" + DUMMY_NODE_ID_VALUE + ":11")))
                 .augmentation(FlowCapableNodeConnectorStatisticsData.class)
                 .child(FlowCapableNodeConnectorStatistics.class);
         verify(txFacade).writeToTransaction(
@@ -402,7 +407,8 @@ public class StatisticsGatheringUtilsTest {
         fireAndCheck(type, statsData);
 
         final KeyedInstanceIdentifier<Queue, QueueKey> queuePath = dummyNodePath
-                .child(NodeConnector.class, new NodeConnectorKey(new NodeConnectorId("openflow:" + DUMMY_NODE_ID_VALUE + ":11")))
+                .child(NodeConnector.class, new NodeConnectorKey(
+                        new NodeConnectorId("openflow:" + DUMMY_NODE_ID_VALUE + ":11")))
                 .augmentation(FlowCapableNodeConnector.class)
                 .child(Queue.class, new QueueKey(new QueueId(queueIdValue)));
         verify(txFacade).writeToTransaction(
@@ -416,17 +422,20 @@ public class StatisticsGatheringUtilsTest {
         final short tableId = 0;
         final MultipartType type = MultipartType.OFPMPFLOW;
 
-        final InstanceIdentifier<FlowCapableNode> nodePath = deviceInfo.getNodeInstanceIdentifier().augmentation(FlowCapableNode.class);
+        final InstanceIdentifier<FlowCapableNode> nodePath
+                = deviceInfo.getNodeInstanceIdentifier().augmentation(FlowCapableNode.class);
         final TableBuilder tableDataBld = new TableBuilder();
         tableDataBld.setId(tableId);
         final FlowCapableNodeBuilder flowNodeBuilder = new FlowCapableNodeBuilder();
         flowNodeBuilder.setTable(Collections.singletonList(tableDataBld.build()));
         final Optional<FlowCapableNode> flowNodeOpt = Optional.of(flowNodeBuilder.build());
-        final CheckedFuture<Optional<FlowCapableNode>, ReadFailedException> flowNodeFuture = Futures.immediateCheckedFuture(flowNodeOpt);
+        final CheckedFuture<Optional<FlowCapableNode>, ReadFailedException> flowNodeFuture
+                = Futures.immediateCheckedFuture(flowNodeOpt);
         when(readTx.read(LogicalDatastoreType.OPERATIONAL, nodePath)).thenReturn(flowNodeFuture);
         when(flowDescriptor.getFlowId()).thenReturn(flowId);
 
-        final org.opendaylight.yang.gen.v1.urn.opendaylight.openflow.oxm.rev150225.match.grouping.MatchBuilder matchBld =
+        final org.opendaylight.yang.gen.v1.urn.opendaylight.openflow.oxm.rev150225.match.grouping.MatchBuilder
+                matchBld =
                 new org.opendaylight.yang.gen.v1.urn.opendaylight.openflow.oxm.rev150225.match.grouping.MatchBuilder()
                         .setMatchEntry(Collections.<MatchEntry>emptyList());
         final FlowStatsBuilder flowStatsBld = new FlowStatsBuilder()
@@ -454,10 +463,12 @@ public class StatisticsGatheringUtilsTest {
                 .child(Table.class, new TableKey((short) 0));
         final KeyedInstanceIdentifier<Flow, FlowKey> flowPath =  tablePath.child(Flow.class, new FlowKey(flowId));
 
-        verify(deviceContext, Mockito.never()).addDeleteToTxChain(Matchers.eq(LogicalDatastoreType.OPERATIONAL), Matchers.<InstanceIdentifier<?>>any());
+        verify(deviceContext, Mockito.never()).addDeleteToTxChain(
+                Matchers.eq(LogicalDatastoreType.OPERATIONAL), Matchers.<InstanceIdentifier<?>>any());
 
         final InOrder inOrder = Mockito.inOrder(txFacade);
-        inOrder.verify(txFacade).writeToTransaction(Matchers.eq(LogicalDatastoreType.OPERATIONAL), Matchers.eq(tablePath), Matchers.any(Table.class));
+        inOrder.verify(txFacade).writeToTransaction(Matchers.eq(
+                LogicalDatastoreType.OPERATIONAL), Matchers.eq(tablePath), Matchers.any(Table.class));
     }
 
     @Test
@@ -472,7 +483,8 @@ public class StatisticsGatheringUtilsTest {
 
         final MultipartReplyMeterConfigBuilder mpReplyMeterConfigBld = new MultipartReplyMeterConfigBuilder();
         mpReplyMeterConfigBld.setMeterConfig(Lists.newArrayList(meterConfigBld.build()));
-        final MultipartReplyMeterConfigCaseBuilder mpReplyMeterConfigCaseBld = new MultipartReplyMeterConfigCaseBuilder();
+        final MultipartReplyMeterConfigCaseBuilder mpReplyMeterConfigCaseBld
+                = new MultipartReplyMeterConfigCaseBuilder();
         mpReplyMeterConfigCaseBld.setMultipartReplyMeterConfig(mpReplyMeterConfigBld.build());
 
         final MultipartReply meterConfigUpdated = assembleMPReplyMessage(type, mpReplyMeterConfigCaseBld.build());
@@ -484,12 +496,16 @@ public class StatisticsGatheringUtilsTest {
                 new org.opendaylight.yang.gen.v1.urn.opendaylight.meter.types.rev130918.MeterId(meterIdValue);
         final KeyedInstanceIdentifier<Meter, MeterKey> meterPath = dummyNodePath.augmentation(FlowCapableNode.class)
                 .child(Meter.class, new MeterKey(meterId));
-        verify(deviceContext, Mockito.never()).addDeleteToTxChain(Matchers.eq(LogicalDatastoreType.OPERATIONAL), Matchers.<InstanceIdentifier<?>>any());
+        verify(deviceContext, Mockito.never()).addDeleteToTxChain(
+                Matchers.eq(LogicalDatastoreType.OPERATIONAL), Matchers.<InstanceIdentifier<?>>any());
         verify(deviceMeterRegistry).store(meterId);
-        verify(txFacade).writeToTransaction(Matchers.eq(LogicalDatastoreType.OPERATIONAL), Matchers.eq(meterPath), Matchers.any(Meter.class));
+        verify(txFacade).writeToTransaction(
+                Matchers.eq(LogicalDatastoreType.OPERATIONAL), Matchers.eq(meterPath), Matchers.any(Meter.class));
     }
 
-    private void fireAndCheck(final MultipartType type, final List<MultipartReply> statsData) throws InterruptedException, ExecutionException, TimeoutException {
+    private void fireAndCheck(
+            final MultipartType type,
+            final List<MultipartReply> statsData) throws InterruptedException, ExecutionException, TimeoutException {
         when(statisticsService.getStatisticsOfType(Matchers.any(EventIdentifier.class), Matchers.eq(type)))
                 .thenReturn(Futures.immediateFuture(RpcResultBuilder.success(statsData).build()));
 
@@ -501,11 +517,13 @@ public class StatisticsGatheringUtilsTest {
                 deviceContext,
                 false,
                 singlePurposeMultipartReplyTranslator);
-        Assert.assertTrue(gatherStatisticsResult.get(1, TimeUnit.SECONDS).booleanValue());
+        Assert.assertTrue(gatherStatisticsResult.get(1, TimeUnit.SECONDS));
         verify(txFacade).submitTransaction();
     }
 
-    private static MultipartReplyMessage assembleMPReplyMessage(final MultipartType type, final MultipartReplyBody mpReplyGroupCaseBld) {
+    private static MultipartReplyMessage assembleMPReplyMessage(
+            final MultipartType type,
+            final MultipartReplyBody mpReplyGroupCaseBld) {
         return new MultipartReplyMessageBuilder()
                 .setMultipartReplyBody(mpReplyGroupCaseBld)
                 .setType(type)
@@ -515,19 +533,22 @@ public class StatisticsGatheringUtilsTest {
     }
 
     private static BucketStats createBucketStat(final long byteCount, final long packetCount) {
-        return new BucketStatsBuilder().setByteCount(BigInteger.valueOf(byteCount)).setPacketCount(BigInteger.valueOf(packetCount)).build();
+        return new BucketStatsBuilder().setByteCount(
+                BigInteger.valueOf(byteCount)).setPacketCount(BigInteger.valueOf(packetCount)).build();
     }
 
     @Test
     public void testDeleteAllKnownFlows() throws Exception {
         final short tableId = 0;
-        final InstanceIdentifier<FlowCapableNode> nodePath = deviceInfo.getNodeInstanceIdentifier().augmentation(FlowCapableNode.class);
+        final InstanceIdentifier<FlowCapableNode> nodePath
+                = deviceInfo.getNodeInstanceIdentifier().augmentation(FlowCapableNode.class);
         final TableBuilder tableDataBld = new TableBuilder();
         tableDataBld.setId(tableId);
         final FlowCapableNodeBuilder flowNodeBuilder = new FlowCapableNodeBuilder();
         flowNodeBuilder.setTable(Collections.singletonList(tableDataBld.build()));
         final Optional<FlowCapableNode> flowNodeOpt = Optional.of(flowNodeBuilder.build());
-        final CheckedFuture<Optional<FlowCapableNode>, ReadFailedException> flowNodeFuture = Futures.immediateCheckedFuture(flowNodeOpt);
+        final CheckedFuture<Optional<FlowCapableNode>, ReadFailedException> flowNodeFuture
+                = Futures.immediateCheckedFuture(flowNodeOpt);
         when(readTx.read(LogicalDatastoreType.OPERATIONAL, nodePath)).thenReturn(flowNodeFuture);
         final KeyedInstanceIdentifier<Table, TableKey> tablePath = deviceInfo.getNodeInstanceIdentifier()
                 .augmentation(FlowCapableNode.class).child(Table.class, new TableKey(tableId));