keith-turner commented on a change in pull request #368: ACCUMULO-4777: fix log 
messages
URL: https://github.com/apache/accumulo/pull/368#discussion_r164130472
 
 

 ##########
 File path: 
server/tserver/src/main/java/org/apache/accumulo/tserver/log/TabletServerLogger.java
 ##########
 @@ -338,9 +338,10 @@ private void write(final Collection<CommitSession> 
sessions, boolean mincFinish,
           success = (currentLogSet == logSetId.get());
         }
       } catch (DfsLogger.LogClosedException ex) {
-        log.debug("Logs closed while writing, retrying attempt " + 
writeRetry.retriesCompleted());
+        log.debug("Logs closed while writing, retrying attempt " + 
(writeRetry.retriesCompleted() + 1));
       } catch (Exception t) {
-        log.warn("Failed to write to WAL, retrying attempt " + 
writeRetry.retriesCompleted(), t);
+        if (writeRetry.retriesCompleted() != 0)
 
 Review comment:
   Could do something like `if(writeRetry.retriesCompleted() % 10 == 0)`  or 
`if(writeRetry.retriesCompleted() % 100 == 0)`.  
   
   With the current change, I think it would be nice if the log message 
indicated that subsequent retires will not be logged.  If logging periodically 
it would be nice to indicate will log again after X failures.

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
[email protected]


With regards,
Apache Git Services

Reply via email to