Bug 7450 : suppressing unnecessary warning logs 24/49924/1
authorPeriyasamy Palanisamy <periyasamy.palanisamy@ericsson.com>
Mon, 2 Jan 2017 05:04:46 +0000 (10:34 +0530)
committerPeriyasamy Palanisamy <periyasamy.palanisamy@ericsson.com>
Mon, 2 Jan 2017 05:04:46 +0000 (10:34 +0530)
* check to remove unncessary alivenessmonitor warn logs while packet
in handling

Change-Id: Ie592618dbf2b1db6d1891b111b14db04c01272eb
Signed-off-by: Periyasamy Palanisamy <periyasamy.palanisamy@ericsson.com>
alivenessmonitor/alivenessmonitor-impl/src/main/java/org/opendaylight/genius/alivenessmonitor/internal/AlivenessMonitor.java

index 5f507d2a94d54a86776fb5414c1c774fd14db3b4..aca5ba9e9dfbb58b187e1814a11b3af0afc02ccd 100644 (file)
@@ -410,8 +410,10 @@ public class AlivenessMonitor implements AlivenessMonitorService, PacketProcessi
                             releaseLock(lock);
                             if (stateChanged) {
                                 //send notifications
-                                LOG.info("Sending notification for monitor Id : {} with Current State: {}",
-                                        currentState.getMonitorId(), LivenessState.Up);
+                                if (LOG.isTraceEnabled()) {
+                                    LOG.trace("Sending notification for monitor Id : {} with Current State: {}",
+                                            currentState.getMonitorId(), LivenessState.Up);
+                                }
                                 publishNotification(currentState.getMonitorId(), LivenessState.Up);
                             } else {
                                 if (LOG.isTraceEnabled()) {
@@ -430,7 +432,10 @@ public class AlivenessMonitor implements AlivenessMonitorService, PacketProcessi
                         }
                     });
                 } else {
-                    LOG.warn("Monitoring State not available for key: {} to process the Packet received", monitorKey);
+                    if (LOG.isTraceEnabled()) {
+                        LOG.trace("Monitoring State not available for key: {} to process the Packet received",
+                                monitorKey);
+                    }
                     //Complete the transaction
                     tx.submit();
                     releaseLock(lock);