Home > other >  Kafka manual confirmation problems
Kafka manual confirmation problems

Time:10-26

@ KafkaListener (switchable viewer={KafkaConstants. ORDER_CREATE_THIRD})
Public void createListen (ConsumerRecord<? ,?> Record, Acknowledgment ack) {
Ack. Acknowledge ();
The info ("====accept parameters after manual submitted + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + ");
Try {
Thread.sleep (10000);
{} catch InterruptedException (e)
e.printStackTrace();
}
}

Springboot projects, such as code, after receiving the data submitted directly confirmed, according to my understanding, since submit confirmation, then can direct consumption of a data, but the reality is wait until the following after sleep will be the next data consumption,
2.1.4 springboot version, spring - kafka version 2.2.7
Ask you, is this why? I want to achieve is to manually submit confirmation, the next data in consumption,
No points, really sorry
  • Related