Uploaded image for project: 'Kafka'
  1. Kafka
  2. KAFKA-16659

KafkaConsumer#position() does not respect wakup when group protocol is CONSUMER

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Minor
    • Resolution: Fixed
    • None
    • 3.8.0
    • None
    • None

    Description

      see following test

        @ParameterizedTest(name = TestInfoUtils.TestWithParameterizedQuorumAndGroupProtocolNames)
        @MethodSource(Array("getTestQuorumAndGroupProtocolParametersAll"))
        @Timeout(15)
        def testPositionRespectsWakeup(quorum: String, groupProtocol: String): Unit = {
          val topicPartition = new TopicPartition(topic, 15)
          val consumer = createConsumer()
          consumer.assign(List(topicPartition).asJava)
      
          CompletableFuture.runAsync { () =>
            TimeUnit.SECONDS.sleep(1)
            consumer.wakeup()
          }
      
          assertThrows(classOf[WakeupException], () => consumer.position(topicPartition, Duration.ofSeconds(3)))
        }
      

      Attachments

        Issue Links

          Activity

            People

              yangpoan PoAn Yang
              chia7712 Chia-Ping Tsai
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: