pivotal-jbarrett commented on code in PR #7584:
URL: https://github.com/apache/geode/pull/7584#discussion_r848842527


##########
geode-core/src/main/java/org/apache/geode/internal/cache/execute/AbstractExecution.java:
##########
@@ -504,8 +508,16 @@ private void handleException(Throwable functionException, 
final Function fn,
         ((InternalResultSender) sender).setException(functionException);
       }
     } else {
-      logger.warn("Exception occurred on local node while executing Function:",
-          functionException);
+      if (AbstractExecution.SUPPRESS_FUNCTION_EXCEPTION_LOGGING
+          && functionException instanceof FunctionException) {
+        if (logger.isDebugEnabled()) {

Review Comment:
   Isn't there a way to do this in log4j with markers or something? It seems 
rather heavy to need an external parameter to toggle the log-level or verbosity 
of this message.
   See [Markers](https://logging.apache.org/log4j/2.x/manual/markers.html).
   > One of the primary purpose of a logging framework is to provide the means 
to generate debugging and diagnostic information only when it is needed, and to 
allow filtering of that information so that it does not overwhelm the system or 
the individuals who need to make use of it.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to