Class KafkaSource<K,V>
- java.lang.Object
-
- io.smallrye.reactive.messaging.kafka.impl.KafkaSource<K,V>
-
public class KafkaSource<K,V> extends Object
-
-
Constructor Summary
Constructors Constructor Description KafkaSource(io.vertx.mutiny.core.Vertx vertx, String consumerGroup, KafkaConnectorIncomingConfiguration config, javax.enterprise.inject.Instance<KafkaConsumerRebalanceListener> consumerRebalanceListeners, KafkaCDIEvents kafkaCDIEvents, javax.enterprise.inject.Instance<DeserializationFailureHandler<?>> deserializationFailureHandlers, int index)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
closeQuietly()
io.smallrye.mutiny.Multi<IncomingKafkaRecordBatch<K,V>>
getBatchStream()
String
getChannel()
KafkaCommitHandler
getCommitHandler()
ReactiveKafkaConsumer<K,V>
getConsumer()
For testing purpose onlyio.smallrye.mutiny.Multi<IncomingKafkaRecord<K,V>>
getStream()
Set<String>
getSubscribedTopics()
boolean
hasSubscribers()
void
incomingTrace(IncomingKafkaRecord<K,V> kafkaRecord, boolean insideBatch)
void
incomingTrace(IncomingKafkaRecordBatch<K,V> kafkaBatchRecord)
void
isAlive(HealthReport.HealthReportBuilder builder)
void
isReady(HealthReport.HealthReportBuilder builder)
void
isStarted(HealthReport.HealthReportBuilder builder)
void
reportFailure(Throwable failure, boolean fatal)
-
-
-
Constructor Detail
-
KafkaSource
public KafkaSource(io.vertx.mutiny.core.Vertx vertx, String consumerGroup, KafkaConnectorIncomingConfiguration config, javax.enterprise.inject.Instance<KafkaConsumerRebalanceListener> consumerRebalanceListeners, KafkaCDIEvents kafkaCDIEvents, javax.enterprise.inject.Instance<DeserializationFailureHandler<?>> deserializationFailureHandlers, int index)
-
-
Method Detail
-
reportFailure
public void reportFailure(Throwable failure, boolean fatal)
-
incomingTrace
public void incomingTrace(IncomingKafkaRecord<K,V> kafkaRecord, boolean insideBatch)
-
incomingTrace
public void incomingTrace(IncomingKafkaRecordBatch<K,V> kafkaBatchRecord)
-
getStream
public io.smallrye.mutiny.Multi<IncomingKafkaRecord<K,V>> getStream()
-
getBatchStream
public io.smallrye.mutiny.Multi<IncomingKafkaRecordBatch<K,V>> getBatchStream()
-
closeQuietly
public void closeQuietly()
-
isAlive
public void isAlive(HealthReport.HealthReportBuilder builder)
-
isReady
public void isReady(HealthReport.HealthReportBuilder builder)
-
isStarted
public void isStarted(HealthReport.HealthReportBuilder builder)
-
getConsumer
public ReactiveKafkaConsumer<K,V> getConsumer()
For testing purpose only- Returns:
- get the underlying consumer.
-
getCommitHandler
public KafkaCommitHandler getCommitHandler()
-
getChannel
public String getChannel()
-
hasSubscribers
public boolean hasSubscribers()
-
-