showuon commented on code in PR #13297:
URL: https://github.com/apache/kafka/pull/13297#discussion_r1117875392


##########
core/src/test/scala/unit/kafka/server/FetchRequestDownConversionConfigTest.scala:
##########
@@ -163,7 +164,9 @@ class FetchRequestDownConversionConfigTest extends 
BaseRequestTest {
   }
 
   def testV1Fetch(isFollowerFetch: Boolean): Unit = {
+    val fetchMessageConversionsTimeMsMetricName = 
s"$MessageConversionsTimeMs,request=Fetch"

Review Comment:
   Yes, we already used the constants from 
`RequestMetrics.MessageConversionsTimeMs`. It's just the fetch/produce request 
is another tag name that needed to be filtered out. Thanks. 



##########
core/src/test/scala/unit/kafka/server/FetchRequestDownConversionConfigTest.scala:
##########
@@ -222,9 +225,14 @@ class FetchRequestDownConversionConfigTest extends 
BaseRequestTest {
     } else {
       assertEquals(Errors.UNSUPPORTED_VERSION, 
error(partitionWithDownConversionDisabled))
     }
+
     TestUtils.waitUntilTrue(() => 
TestUtils.metersCount(BrokerTopicStats.FetchMessageConversionsPerSec) > 
initialFetchMessageConversionsPerSec,
       s"The `FetchMessageConversionsPerSec` metric count is not incremented 
after 5 seconds. " +
       s"init: $initialFetchMessageConversionsPerSec final: 
${TestUtils.metersCount(BrokerTopicStats.FetchMessageConversionsPerSec)}", 5000)
+
+    TestUtils.waitUntilTrue(() => 
TestUtils.metersCount(fetchMessageConversionsTimeMsMetricName) > 
initialFetchMessageConversionsTimeMs,
+      s"The `MessageConversionsTimeMs` in fetch request metric count is not 
incremented after 5 seconds. " +
+      s"init: $initialFetchMessageConversionsTimeMs final: 
${TestUtils.metersCount(fetchMessageConversionsTimeMsMetricName)}", 5000)

Review Comment:
   Good point. Updated.



-- 
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: jira-unsubscr...@kafka.apache.org

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

Reply via email to