Lower debugging in sal-clustering-commons 41/57141/2
authorRobert Varga <robert.varga@pantheon.tech>
Tue, 16 May 2017 11:54:24 +0000 (13:54 +0200)
committerMichael Vorburger <vorburger@redhat.com>
Tue, 16 May 2017 23:41:51 +0000 (23:41 +0000)
Since this component is under controller.cluster.datastore,
it floods logs with serialization details when we really just
want to understand what the data store is doing. Lower the logs
to TRACE.

Change-Id: Ib9a4735bc439a726452fb98fb5f79d2b7dea2047
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
opendaylight/md-sal/sal-clustering-commons/src/main/java/org/opendaylight/controller/cluster/datastore/node/utils/stream/AbstractNormalizedNodeDataOutput.java
opendaylight/md-sal/sal-clustering-commons/src/main/java/org/opendaylight/controller/cluster/datastore/node/utils/stream/NormalizedNodeInputStreamReader.java

index 2e5b804..a057a35 100644 (file)
@@ -211,7 +211,7 @@ abstract class AbstractNormalizedNodeDataOutput implements NormalizedNodeDataOut
             throws IOException, IllegalArgumentException {
         Preconditions.checkNotNull(name, "Node identifier should not be null");
 
-        LOG.debug("Starting a new container node");
+        LOG.trace("Starting a new container node");
 
         startNode(name.getNodeType(), NodeTypes.CONTAINER_NODE);
     }
@@ -268,7 +268,7 @@ abstract class AbstractNormalizedNodeDataOutput implements NormalizedNodeDataOut
     public void startOrderedMapNode(final NodeIdentifier name, final int childSizeHint)
             throws IOException, IllegalArgumentException {
         Preconditions.checkNotNull(name, "Node identifier should not be null");
-        LOG.debug("Starting a new ordered map node");
+        LOG.trace("Starting a new ordered map node");
 
         startNode(name.getNodeType(), NodeTypes.ORDERED_MAP_NODE);
     }
index 831c516..4cc63d0 100644 (file)
@@ -117,7 +117,7 @@ public class NormalizedNodeInputStreamReader implements NormalizedNodeDataInput
         byte nodeType = input.readByte();
 
         if (nodeType == NodeTypes.END_NODE) {
-            LOG.debug("End node reached. return");
+            LOG.trace("End node reached. return");
             return null;
         }
 
@@ -126,7 +126,7 @@ public class NormalizedNodeInputStreamReader implements NormalizedNodeDataInput
                 YangInstanceIdentifier.AugmentationIdentifier augIdentifier =
                     new YangInstanceIdentifier.AugmentationIdentifier(readQNameSet());
 
-                LOG.debug("Reading augmentation node {} ", augIdentifier);
+                LOG.trace("Reading augmentation node {} ", augIdentifier);
 
                 return addDataContainerChildren(Builders.augmentationBuilder()
                         .withNodeIdentifier(augIdentifier)).build();
@@ -140,7 +140,7 @@ public class NormalizedNodeInputStreamReader implements NormalizedNodeDataInput
                 Object value = readObject();
                 NodeWithValue<Object> leafIdentifier = new NodeWithValue<>(name, value);
 
-                LOG.debug("Reading leaf set entry node {}, value {}", leafIdentifier, value);
+                LOG.trace("Reading leaf set entry node {}, value {}", leafIdentifier, value);
 
                 return leafSetEntryBuilder().withNodeIdentifier(leafIdentifier).withValue(value).build();
 
@@ -148,7 +148,7 @@ public class NormalizedNodeInputStreamReader implements NormalizedNodeDataInput
                 NodeIdentifierWithPredicates entryIdentifier = new NodeIdentifierWithPredicates(
                         readQName(), readKeyValueMap());
 
-                LOG.debug("Reading map entry node {} ", entryIdentifier);
+                LOG.trace("Reading map entry node {} ", entryIdentifier);
 
                 return addDataContainerChildren(Builders.mapEntryBuilder()
                         .withNodeIdentifier(entryIdentifier)).build();
@@ -182,46 +182,46 @@ public class NormalizedNodeInputStreamReader implements NormalizedNodeDataInput
 
         switch (nodeType) {
             case NodeTypes.LEAF_NODE :
-                LOG.debug("Read leaf node {}", identifier);
+                LOG.trace("Read leaf node {}", identifier);
                 // Read the object value
                 return leafBuilder().withNodeIdentifier(identifier).withValue(readObject()).build();
 
             case NodeTypes.ANY_XML_NODE :
-                LOG.debug("Read xml node");
+                LOG.trace("Read xml node");
                 return Builders.anyXmlBuilder().withNodeIdentifier(identifier).withValue(readDOMSource()).build();
 
             case NodeTypes.MAP_NODE :
-                LOG.debug("Read map node {}", identifier);
+                LOG.trace("Read map node {}", identifier);
                 return addDataContainerChildren(Builders.mapBuilder().withNodeIdentifier(identifier)).build();
 
             case NodeTypes.CHOICE_NODE:
-                LOG.debug("Read choice node {}", identifier);
+                LOG.trace("Read choice node {}", identifier);
                 return addDataContainerChildren(Builders.choiceBuilder().withNodeIdentifier(identifier)).build();
 
             case NodeTypes.ORDERED_MAP_NODE:
-                LOG.debug("Reading ordered map node {}", identifier);
+                LOG.trace("Reading ordered map node {}", identifier);
                 return addDataContainerChildren(Builders.orderedMapBuilder().withNodeIdentifier(identifier)).build();
 
             case NodeTypes.UNKEYED_LIST:
-                LOG.debug("Read unkeyed list node {}", identifier);
+                LOG.trace("Read unkeyed list node {}", identifier);
                 return addDataContainerChildren(Builders.unkeyedListBuilder().withNodeIdentifier(identifier)).build();
 
             case NodeTypes.UNKEYED_LIST_ITEM:
-                LOG.debug("Read unkeyed list item node {}", identifier);
+                LOG.trace("Read unkeyed list item node {}", identifier);
                 return addDataContainerChildren(Builders.unkeyedListEntryBuilder()
                         .withNodeIdentifier(identifier)).build();
 
             case NodeTypes.CONTAINER_NODE:
-                LOG.debug("Read container node {}", identifier);
+                LOG.trace("Read container node {}", identifier);
                 return addDataContainerChildren(Builders.containerBuilder().withNodeIdentifier(identifier)).build();
 
             case NodeTypes.LEAF_SET :
-                LOG.debug("Read leaf set node {}", identifier);
+                LOG.trace("Read leaf set node {}", identifier);
                 return addLeafSetChildren(identifier.getNodeType(),
                         Builders.leafSetBuilder().withNodeIdentifier(identifier)).build();
 
             case NodeTypes.ORDERED_LEAF_SET:
-                LOG.debug("Read ordered leaf set node {}", identifier);
+                LOG.trace("Read ordered leaf set node {}", identifier);
                 ListNodeBuilder<Object, LeafSetEntryNode<Object>> orderedLeafSetBuilder =
                         Builders.orderedLeafSetBuilder().withNodeIdentifier(identifier);
                 orderedLeafSetBuilder = addLeafSetChildren(identifier.getNodeType(), orderedLeafSetBuilder);
@@ -421,7 +421,7 @@ public class NormalizedNodeInputStreamReader implements NormalizedNodeDataInput
     private ListNodeBuilder<Object, LeafSetEntryNode<Object>> addLeafSetChildren(final QName nodeType,
             final ListNodeBuilder<Object, LeafSetEntryNode<Object>> builder) throws IOException {
 
-        LOG.debug("Reading children of leaf set");
+        LOG.trace("Reading children of leaf set");
 
         lastLeafSetQName = nodeType;
 
@@ -437,7 +437,7 @@ public class NormalizedNodeInputStreamReader implements NormalizedNodeDataInput
     @SuppressWarnings({ "unchecked", "rawtypes" })
     private NormalizedNodeContainerBuilder addDataContainerChildren(
             final NormalizedNodeContainerBuilder builder) throws IOException {
-        LOG.debug("Reading data container (leaf nodes) nodes");
+        LOG.trace("Reading data container (leaf nodes) nodes");
 
         NormalizedNode<?, ?> child = readNormalizedNodeInternal();
 

©2013 OpenDaylight, A Linux Foundation Collaborative Project. All Rights Reserved.
OpenDaylight is a registered trademark of The OpenDaylight Project, Inc.
Linux Foundation and OpenDaylight are registered trademarks of the Linux Foundation.
Linux is a registered trademark of Linus Torvalds.