Package com.consol.citrus.kafka.endpoint
Class KafkaConsumer
- java.lang.Object
-
- com.consol.citrus.messaging.AbstractMessageConsumer
-
- com.consol.citrus.kafka.endpoint.KafkaConsumer
-
- All Implemented Interfaces:
com.consol.citrus.messaging.Consumer
public class KafkaConsumer extends com.consol.citrus.messaging.AbstractMessageConsumer- Since:
- 2.8
- Author:
- Christoph Deppisch
-
-
Field Summary
Fields Modifier and Type Field Description protected KafkaEndpointConfigurationendpointConfigurationEndpoint configuration
-
Constructor Summary
Constructors Constructor Description KafkaConsumer(String name, KafkaEndpointConfiguration endpointConfiguration)Default constructor using endpoint.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Messagereceive(TestContext context, long timeout)voidsetConsumer(org.apache.kafka.clients.consumer.KafkaConsumer<Object,Object> consumer)Sets the consumer.voidstop()Stop message listener container.
-
-
-
Field Detail
-
endpointConfiguration
protected final KafkaEndpointConfiguration endpointConfiguration
Endpoint configuration
-
-
Constructor Detail
-
KafkaConsumer
public KafkaConsumer(String name, KafkaEndpointConfiguration endpointConfiguration)
Default constructor using endpoint.- Parameters:
name-endpointConfiguration-
-
-
Method Detail
-
receive
public Message receive(TestContext context, long timeout)
-
stop
public void stop()
Stop message listener container.
-
-