func chunkedWriteStoreShard(store *tsdb.Store, shardID int, points []tsdb.Point) { nPts := len(points) chunkSz := 10000 start := 0 end := chunkSz for { if end > nPts { end = nPts } if end-start == 0 { break } store.WriteToShard(uint64(shardID), points[start:end]) start = end end += chunkSz } }