Eyal Yurman
08/04/2025, 7:18 PMEyal Yurman
08/04/2025, 7:19 PM"tuningConfig": {
"type": "kafka",
"appendableIndexSpec": {
"type": "onheap",
"preserveExistingMetrics": false
},
"maxRowsInMemory": 150000,
"maxBytesInMemory": 0,
"skipBytesInMemoryOverheadCheck": false,
"maxRowsPerSegment": 5000000,
"maxTotalRows": null,
"intermediatePersistPeriod": "PT10M",
"maxPendingPersists": 0,
"indexSpec": {
"bitmap": {
"type": "roaring"
},
"dimensionCompression": "lz4",
"stringDictionaryEncoding": {
"type": "utf8"
},
"metricCompression": "lz4",
"longEncoding": "longs"
},
"indexSpecForIntermediatePersists": {
"bitmap": {
"type": "roaring"
},
"dimensionCompression": "lz4",
"stringDictionaryEncoding": {
"type": "utf8"
},
"metricCompression": "lz4",
"longEncoding": "longs"
},
"reportParseExceptions": false,
"handoffConditionTimeout": 900000,
"resetOffsetAutomatically": false,
"segmentWriteOutMediumFactory": null,
"workerThreads": 2,
"chatRetries": 8,
"httpTimeout": "PT10S",
"shutdownTimeout": "PT80S",
"offsetFetchPeriod": "PT30S",
"intermediateHandoffPeriod": "P2D",
"logParseExceptions": false,
"maxParseExceptions": 0,
"maxSavedParseExceptions": 1000,
"numPersistThreads": 1,
"maxColumnsToMerge": -1,
"skipSequenceNumberAvailabilityCheck": false,
"repartitionTransitionDuration": "PT120S"
}Eyal Yurman
08/04/2025, 7:20 PMSELECT ABS("num_rows" / 1000000) as "bucket",
COUNT(*) as segments,
SUM("size") / 1048576 as totalSizeMiB,
MIN("size") / 1048576 as minSizeMiB,
AVG("size") / 1048576 as averageSizeMiB,
MAX("size") / 1048576 as maxSizeMiB,
SUM("num_rows") as totalRows,
MIN("num_rows") as minRows,
AVG("num_rows") as averageRows,
MAX("num_rows") as maxRows,
(AVG("size") / AVG("num_rows")) as avgRowSizeB
FROM sys.segments
WHERE is_available = 1 AND is_realtime = 0 AND datasource = 'foo'
GROUP BY 1
ORDER BY 1;
| bucket | segments | totalSizeMiB | minSizeMiB | averageSizeMiB | maxSizeMiB | totalRows | minRows | averageRows | maxRows | avgRowSizeB |
| -----: | -------: | -----------: | ---------: | -----------------: | ---------: | --------: | ------: | ----------------: | ------: | ----------------: |
| 0 | 718 | 1179 | 0 | 1.6434304176266812 | 2 | 3814744 | 1 | 5313.013927576601 | 7249 | 324.3472946022066 |John Kowtko
08/05/2025, 12:27 AMBen Krug
08/05/2025, 10:00 PM