Package io.trino.testing.kafka
Class TestingKafka
java.lang.Object
io.trino.testing.kafka.TestingKafka
- All Implemented Interfaces:
Closeable,AutoCloseable
-
Method Summary
Modifier and TypeMethodDescriptionvoidclose()static TestingKafkacreate()static TestingKafkavoidcreateTopic(String topic) voidcreateTopicWithConfig(int partitions, int replication, String topic, boolean enableLogAppendTime) static TestingKafkaorg.testcontainers.containers.Network<K,V> org.apache.kafka.clients.producer.RecordMetadata sendMessages(Stream<org.apache.kafka.clients.producer.ProducerRecord<K, V>> recordStream) <K,V> org.apache.kafka.clients.producer.RecordMetadata sendMessages(Stream<org.apache.kafka.clients.producer.ProducerRecord<K, V>> recordStream, Map<String, String> extraProducerProperties) voidstart()
-
Method Details
-
create
-
create
-
createWithSchemaRegistry
-
start
public void start() -
close
- Specified by:
closein interfaceAutoCloseable- Specified by:
closein interfaceCloseable- Throws:
IOException
-
createTopic
-
createTopicWithConfig
public void createTopicWithConfig(int partitions, int replication, String topic, boolean enableLogAppendTime) -
sendMessages
public <K,V> org.apache.kafka.clients.producer.RecordMetadata sendMessages(Stream<org.apache.kafka.clients.producer.ProducerRecord<K, V>> recordStream) -
sendMessages
-
getConnectString
-
getSchemaRegistryConnectString
-
getNetwork
public org.testcontainers.containers.Network getNetwork()
-