Class VeniceKafkaInputMapper
java.lang.Object
com.linkedin.venice.hadoop.task.datawriter.AbstractDataWriterTask
com.linkedin.venice.hadoop.task.datawriter.AbstractInputRecordProcessor<INPUT_KEY,INPUT_VALUE>
com.linkedin.venice.hadoop.mapreduce.datawriter.map.AbstractVeniceMapper<KafkaInputMapperKey,KafkaInputMapperValue>
com.linkedin.venice.hadoop.input.kafka.VeniceKafkaInputMapper
- All Implemented Interfaces:
Closeable
,AutoCloseable
,org.apache.hadoop.io.Closeable
,org.apache.hadoop.mapred.JobConfigurable
,org.apache.hadoop.mapred.Mapper<KafkaInputMapperKey,
KafkaInputMapperValue, org.apache.hadoop.io.BytesWritable, org.apache.hadoop.io.BytesWritable>
public class VeniceKafkaInputMapper
extends AbstractVeniceMapper<KafkaInputMapperKey,KafkaInputMapperValue>
This class is designed specifically for
KafkaInputFormat
, and right now, it is doing simple pass-through.-
Field Summary
Fields inherited from class com.linkedin.venice.hadoop.task.datawriter.AbstractInputRecordProcessor
veniceRecordReader
Fields inherited from class com.linkedin.venice.hadoop.task.datawriter.AbstractDataWriterTask
TASK_ID_NOT_SET
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
close()
protected void
configureTask
(VeniceProperties props) Allow implementations of this class to configure task-specific stuff.protected FilterChain<KafkaInputMapperValue>
getFilterChain
(VeniceProperties props) getRecordReader
(VeniceProperties props) A method for child classes to setupAbstractInputRecordProcessor.veniceRecordReader
.protected boolean
process
(KafkaInputMapperKey inputKey, KafkaInputMapperValue inputValue, AtomicReference<byte[]> keyRef, AtomicReference<byte[]> valueRef, DataWriterTaskTracker dataWriterTaskTracker) This function will return true if the input key/value pair is valid.Methods inherited from class com.linkedin.venice.hadoop.mapreduce.datawriter.map.AbstractVeniceMapper
configure, map
Methods inherited from class com.linkedin.venice.hadoop.task.datawriter.AbstractInputRecordProcessor
processRecord, readDictionaryFromKafka
Methods inherited from class com.linkedin.venice.hadoop.task.datawriter.AbstractDataWriterTask
configure, getEngineTaskConfigProvider, getPartitionCount, getTaskId, isChunkingEnabled, isRmdChunkingEnabled, setChunkingEnabled
-
Constructor Details
-
VeniceKafkaInputMapper
public VeniceKafkaInputMapper()
-
-
Method Details
-
getRecordReader
protected AbstractVeniceRecordReader<KafkaInputMapperKey,KafkaInputMapperValue> getRecordReader(VeniceProperties props) Description copied from class:AbstractInputRecordProcessor
A method for child classes to setupAbstractInputRecordProcessor.veniceRecordReader
.- Specified by:
getRecordReader
in classAbstractInputRecordProcessor<KafkaInputMapperKey,
KafkaInputMapperValue>
-
getFilterChain
-
configureTask
Description copied from class:AbstractDataWriterTask
Allow implementations of this class to configure task-specific stuff.- Overrides:
configureTask
in classAbstractInputRecordProcessor<KafkaInputMapperKey,
KafkaInputMapperValue> - Parameters:
props
- the job props that the task was configured with.
-
process
protected boolean process(KafkaInputMapperKey inputKey, KafkaInputMapperValue inputValue, AtomicReference<byte[]> keyRef, AtomicReference<byte[]> valueRef, DataWriterTaskTracker dataWriterTaskTracker) Description copied from class:AbstractInputRecordProcessor
This function will return true if the input key/value pair is valid.- Overrides:
process
in classAbstractInputRecordProcessor<KafkaInputMapperKey,
KafkaInputMapperValue>
-
close
public void close()- Specified by:
close
in interfaceAutoCloseable
- Specified by:
close
in interfaceCloseable
- Overrides:
close
in classAbstractInputRecordProcessor<KafkaInputMapperKey,
KafkaInputMapperValue>
-