kirklund commented on a change in pull request #7299:
URL: https://github.com/apache/geode/pull/7299#discussion_r793149989



##########
File path: 
geode-serialization/src/main/java/org/apache/geode/internal/serialization/filter/GlobalSerialFilterConfiguration.java
##########
@@ -93,32 +107,45 @@ public boolean configure() {
       globalSerialFilter.setFilter();
 
       // log statement that filter is now configured
-      logger.accept("Global serial filter is now configured.");
+      infoLogger.accept("Global serial filter is now configured.");
       return true;
 
     } catch (UnsupportedOperationException e) {
-      if (hasRootCauseWithMessage(e, IllegalStateException.class,
-          "Serial filter can only be set once")) {
-
-        // log statement that filter was already configured
-        logger.accept("Global serial filter is already configured.");
-      }
+      handleUnsupportedOperationException(e);
       return false;
     }
   }
 
-  private static boolean hasRootCauseWithMessage(Throwable throwable,
+  private void 
handleUnsupportedOperationException(UnsupportedOperationException e) {
+    if (hasRootCauseWithMessageContaining(e, IllegalStateException.class,
+        "Serial filter can only be set once")) {
+
+      // log statement that filter was already configured
+      warnLogger.accept("Global serial filter is already configured.");

Review comment:
       I changed the logging statements to be consistent. I left this one at 
WARNING level and lowered the ERROR statement to WARNING as well. I also added 
information for the User to address the cause of the warnings.




-- 
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