Stream Ingestion (Local)
Step-by-step guide for streaming ingestion into a local Pinot installation
Set up Kafka
bin/pinot-admin.sh StartKafka -zkAddress=localhost:2123/kafka -port 9876bin/kafka-topics.sh --create --bootstrap-server localhost:9876 \
--replication-factor 1 --partitions 1 --topic transcript-topicCreate a schema
Create a table configuration
{
"tableName": "transcript",
"tableType": "REALTIME",
"segmentsConfig": {
"timeColumnName": "timestampInEpoch",
"timeType": "MILLISECONDS",
"schemaName": "transcript",
"replicasPerPartition": "1"
},
"tenants": {},
"tableIndexConfig": {
"loadMode": "MMAP",
"streamConfigs": {
"streamType": "kafka",
"stream.kafka.topic.name": "transcript-topic",
"stream.kafka.decoder.class.name": "org.apache.pinot.plugin.inputformat.json.JSONMessageDecoder",
"stream.kafka.consumer.factory.class.name": "org.apache.pinot.plugin.stream.kafka30.KafkaConsumerFactory",
"stream.kafka.broker.list": "localhost:9876",
"realtime.segment.flush.threshold.rows": "0",
"realtime.segment.flush.threshold.time": "24h",
"realtime.segment.flush.threshold.segment.size": "50M",
"stream.kafka.consumer.prop.auto.offset.reset": "smallest"
}
},
"metadata": {
"customConfigs": {}
}
}Upload the schema and table configuration
Load sample data into the stream
Query your data
Last updated
Was this helpful?

