Apache kafka 手动关闭旧Kafka事务

Apache kafka 手动关闭旧Kafka事务,apache-kafka,transactions,Apache Kafka,Transactions,我们的一个卡夫卡集群(卡夫卡版本2.2.1)存在问题。一些uu消费者u偏移分区未被清理,大小为10s GB(正常的分区大小为10s MB) LogCleaner提到: [2019-06-17 12:27:26,147] DEBUG Finding range of cleanable offsets for log=__consumer_offsets-13 topicPartition=__consumer_offsets-13. Last clean offset=Some(45461829

我们的一个卡夫卡集群(卡夫卡版本2.2.1)存在问题。一些uu消费者u偏移分区未被清理,大小为10s GB(正常的分区大小为10s MB)

LogCleaner提到:

[2019-06-17 12:27:26,147] DEBUG Finding range of cleanable offsets for log=__consumer_offsets-13 topicPartition=__consumer_offsets-13. Last clean offset=Some(4546182967) now=1560774446127 => firstDirtyOffset=4546182967 firstUncleanableOffset=4737493473 activeSegment.baseOffset=5008571978 (kafka.log.LogCleanerManager$)
因此,根据LogCleaner,偏移量4737493473不应被清理。 这是一个非常旧的偏移量,因此我们进一步查找,并在该分区的最新*.snapshot文件中找到:

/usr/kafka/bin/kafka-dump-log.sh --files /data/__consumer_offsets-13/00000000005012457913.snapshot | grep 4737493473
producerId: 574024 producerEpoch: 24 coordinatorEpoch: 114 currentTxnFirstOffset: Some(4737493473) firstSequence: 0 lastSequence: 0 lastOffset: 4737493473 offsetDelta: 0 timestamp: 1558689306384
因此,抵消似乎是正在进行的交易的一部分。我的问题是,我们能做些什么使日志清理器移过这个偏移量?我们是否可以手动关闭该交易、删除该交易或执行其他操作


最好的祝愿

Thomas Larsson:在测试事务性生产者之后,我们似乎也遇到了类似的问题。你解决了这个问题吗?