davsclaus commented on PR #7387:
URL: https://github.com/apache/camel/pull/7387#issuecomment-1094712449

   Hi Great work so far
   
   I think pausing should be possible both manually and automatic. The former 
is to integrate with Camel's existing Lifecycle with the suspend/resume on the 
Camel Service.
   
   1) manual
   KafkaConsumer (from kafka-client) have its own pause/resume API, which seems 
to not be in use. I think camel end users would want camel-kafka to use these 
APIs for pausing.
   
   Camel has suspend/resume operations on a route (can call via Java or JMX) so 
users can force a pauses/resume. I think the camel kafka consumer should then 
implement Suspendable and then the doSuspend/doResume operations should then 
trigger the kafka-client pauses/resume methods.
   
   2) automatic
   The generic way with a "boolean" seems a bit more more like a readiness 
check that would break out the poll loop, which you can then "configure" or 
"customize" to make it automatic. I wonder if the BooleanSupplier API is a bit 
too simplistic? You may need access to the Camel Consumer so you have a way to 
use information from there to know if you can continue or not. 
   
   
   


-- 
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: commits-unsubscr...@camel.apache.org

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

Reply via email to