You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@ranger.apache.org by ab...@apache.org on 2021/12/17 19:56:20 UTC

[ranger] branch master updated: RANGER-3556: Ranger tagsync logs unnecessary messages

This is an automated email from the ASF dual-hosted git repository.

abhay pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/ranger.git


The following commit(s) were added to refs/heads/master by this push:
     new d6f0196  RANGER-3556: Ranger tagsync logs unnecessary messages
d6f0196 is described below

commit d6f0196bcbde1c0202ee978ebd007003911842f9
Author: Abhay Kulkarni <ab...@apache.org>
AuthorDate: Fri Dec 17 11:56:04 2021 -0800

    RANGER-3556: Ranger tagsync logs unnecessary messages
---
 .../org/apache/ranger/tagsync/source/atlas/AtlasTagSource.java    | 8 ++++++--
 1 file changed, 6 insertions(+), 2 deletions(-)

diff --git a/tagsync/src/main/java/org/apache/ranger/tagsync/source/atlas/AtlasTagSource.java b/tagsync/src/main/java/org/apache/ranger/tagsync/source/atlas/AtlasTagSource.java
index e9fe02f..41ef181 100644
--- a/tagsync/src/main/java/org/apache/ranger/tagsync/source/atlas/AtlasTagSource.java
+++ b/tagsync/src/main/java/org/apache/ranger/tagsync/source/atlas/AtlasTagSource.java
@@ -190,7 +190,9 @@ public class AtlasTagSource extends AbstractTagSource {
 					List<AtlasKafkaMessage<EntityNotification>> newMessages = consumer.receive(MAX_WAIT_TIME_IN_MILLIS);
 
 					if (newMessages.size() == 0) {
-						LOG.info("AtlasTagSource.ConsumerRunnable.run: no message from NotificationConsumer within " + MAX_WAIT_TIME_IN_MILLIS + " milliseconds");
+						if (LOG.isDebugEnabled()) {
+							LOG.debug("AtlasTagSource.ConsumerRunnable.run: no message from NotificationConsumer within " + MAX_WAIT_TIME_IN_MILLIS + " milliseconds");
+						}
 						if (CollectionUtils.isNotEmpty(atlasEntitiesWithTags)) {
 							buildAndUploadServiceTags();
 						}
@@ -274,7 +276,9 @@ public class AtlasTagSource extends AbstractTagSource {
 					updateSink(entry.getValue());
 				}
 				offsetOfLastMessageDeliveredToRanger = messages.get(messages.size()-1).getOffset();
-				LOG.info("Completed processing batch of messages of size:[" + messages.size() + "] received from NotificationConsumer");
+				if (LOG.isDebugEnabled()) {
+					LOG.debug("Completed processing batch of messages of size:[" + messages.size() + "] received from NotificationConsumer");
+				}
 
 				commitToKafka();
 			}