| Pinot Version | 1.0.0 |
|---|---|
| Code | startreedata/pinot-recipes/time-boundary-hybrid-table |
For more information on time boundaries, see Concepts: Time Boundary
Prerequisites
To follow the code examples in this guide, you must install Docker locally and download recipes.Navigate to recipe
- If you haven’t already, download recipes.
- In terminal, go to the recipe by running the following command:
Makefile
The Makefile contains all of the commands need to start up Pinot and Kafka. Run the make command below.make recipe
This command will also:
- Create a Kafka topic called
events. - Create a hybrid Pinot
eventstable. - Batch load data into the offline
eventstable in Pinot. - Generate stream data using the Pinot schema to Kafka and ultimately into the realtime
eventstable in Pinot.
events_REALTIME and an events_OFFLINE table. When you go to the query console in Pinot, you will only see one table: events.
Select Pinot Segments
The stream data generator will generate 1000 records into theevents_REALTIME table. The batch loader will load 10 records into the events_OFFLINE table for a total of 1010 records.
If you count the number of records in this table, you will only get 1000.
query response stats you’ll see 1000 documents scanned from 1010 totalDocs. When querying hybrid tables, the Pinot Broker must decide which records to read from the offline table and which to read from the real-time table.
If you run the SQL below, you’ll see that there are no OFFLINE segments. They are only realtime segments.
event table’s time boundary.

