mirror of
https://github.com/VictoriaMetrics/VictoriaMetrics.git
synced 2025-01-20 07:19:17 +01:00
lib/storage: reduce the amounts of memory which can be occupied by rawRow items during data ingestion on a system with many CPU cores
This commit is contained in:
parent
67b17cdd68
commit
044ab46824
@ -82,7 +82,7 @@ var rawRowsShardsPerPartition = (cgroup.AvailableCPUs() + 7) / 8
|
||||
// getMaxRowsPerPartition returns the maximum number of rows that haven't been converted into parts yet.
|
||||
func getMaxRawRowsPerPartition() int {
|
||||
maxRawRowsPerPartitionOnce.Do(func() {
|
||||
n := memory.Allowed() / 256 / int(unsafe.Sizeof(rawRow{}))
|
||||
n := memory.Allowed() / rawRowsShardsPerPartition / 256 / int(unsafe.Sizeof(rawRow{}))
|
||||
if n < 1e4 {
|
||||
n = 1e4
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user