Class SensorTest

java.lang.Object
org.apache.kafka.common.metrics.SensorTest

public class SensorTest extends Object
  • Constructor Details

    • SensorTest

      public SensorTest()
  • Method Details

    • testRecordLevelEnum

      @Test public void testRecordLevelEnum()
    • testShouldRecordForInfoLevelSensor

      @Test public void testShouldRecordForInfoLevelSensor()
    • testShouldRecordForDebugLevelSensor

      @Test public void testShouldRecordForDebugLevelSensor()
    • testShouldRecordForTraceLevelSensor

      @Test public void testShouldRecordForTraceLevelSensor()
    • testExpiredSensor

      @Test public void testExpiredSensor()
    • testIdempotentAdd

      @Test public void testIdempotentAdd()
    • testIdempotentAddStat

      @Test public void testIdempotentAddStat()
    • testCheckQuotasInMultiThreads

      @Test public void testCheckQuotasInMultiThreads() throws InterruptedException, ExecutionException
      The Sensor#checkQuotas should be thread-safe since the method may be used by many ReplicaFetcherThreads.
      Throws:
      InterruptedException
      ExecutionException
    • shouldReturnPresenceOfMetrics

      @Test public void shouldReturnPresenceOfMetrics()
    • testStrictQuotaEnforcementWithRate

      @Test public void testStrictQuotaEnforcementWithRate()
    • testStrictQuotaEnforcementWithTokenBucket

      @Test public void testStrictQuotaEnforcementWithTokenBucket()
    • testRecordAndCheckQuotaUseMetricConfigOfEachStat

      @Test public void testRecordAndCheckQuotaUseMetricConfigOfEachStat()
    • testUpdatingMetricConfigIsReflectedInTheSensor

      @Test public void testUpdatingMetricConfigIsReflectedInTheSensor()
    • testGetQuotaViolationsReturnsQuotasForParentSensors

      @Test public void testGetQuotaViolationsReturnsQuotasForParentSensors()
    • testOnRemovalCallsRemoveCallback

      @Test public void testOnRemovalCallsRemoveCallback()