dongjinleekr commented on a change in pull request #9266:
URL: https://github.com/apache/kafka/pull/9266#discussion_r490383726



##########
File path: core/src/test/scala/kafka/utils/LoggingTest.scala
##########
@@ -58,4 +60,20 @@ class LoggingTest extends Logging {
 
     assertEquals(logging.getClass.getName, logging.log.underlying.getName)
   }
+
+  @Test
+  def testLoggerLevelIsResolved(): Unit = {
+    val controller = new Log4jController()
+    val previousLevel = controller.getLogLevel("kafka")
+    try {
+      controller.setLogLevel("kafka", "TRACE")
+      
Logger(LoggerFactory.getLogger("kafka.utils.Log4jControllerTest")).trace("test")

Review comment:
       I verified that it works without 
`com.typesafe.scalalogging.Logger#apply` here, i.e.,  
`LoggerFactory.getLogger("kafka.utils.Log4jControllerTest").trace("test")`. 
Other test cases like `RestServerTest` don't invoke it. It would be better to 
remove 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.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


Reply via email to