Package io.deephaven.kafka.ingest
Class GenericRecordConsumerRecordToTableWriterAdapter
java.lang.Object
io.deephaven.kafka.ingest.GenericRecordConsumerRecordToTableWriterAdapter
- All Implemented Interfaces:
ConsumerRecordToTableWriterAdapter
public class GenericRecordConsumerRecordToTableWriterAdapter
extends Object
implements ConsumerRecordToTableWriterAdapter
Convert an Avro
GenericRecord
to Deephaven rows.
Each GenericRecord produces a single row of output, according to the maps of Table column names to Avro field names
for the keys and values.-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic class
A builder to map key and value fields to table columns. -
Method Summary
Modifier and TypeMethodDescriptionvoid
consumeRecord
(org.apache.kafka.clients.consumer.ConsumerRecord<?, ?> record, DBDateTime recvTime) Consume a Kafka record, producing zero or more rows in the output.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface io.deephaven.kafka.ingest.ConsumerRecordToTableWriterAdapter
close, consumeRecord, defaultConsumeRecord, setAsyncErrorHandler, setAsyncStatusUpdater
-
Method Details
-
consumeRecord
public void consumeRecord(org.apache.kafka.clients.consumer.ConsumerRecord<?, ?> record, DBDateTime recvTime) throws IOExceptionDescription copied from interface:ConsumerRecordToTableWriterAdapter
Consume a Kafka record, producing zero or more rows in the output.- Specified by:
consumeRecord
in interfaceConsumerRecordToTableWriterAdapter
- Parameters:
record
- the record received fromKafkaConsumer.poll(Duration)
.recvTime
- the time the record was received fromKafkaConsumer.poll(Duration)
.- Throws:
IOException
- if there was an error writing to the output table
-