test: throttle history verification

This commit is contained in:
richjohnrambo
2026-09-28 08:17:14 +08:00
parent cb2210aa3e
commit d3c679878d
9 changed files with 141 additions and 10 deletions
+2 -2
View File
@@ -90,13 +90,13 @@ func loadConfig(path string) (*Config, error) {
return nil, errors.New("history_workers must not exceed 128")
}
if cfg.HistoryPageSize <= 0 {
cfg.HistoryPageSize = 50
cfg.HistoryPageSize = 20
}
if cfg.HistoryPageSize > 200 {
return nil, errors.New("history_page_size must not exceed 200")
}
if cfg.HistoryInterval == "" {
cfg.HistoryInterval = "100ms"
cfg.HistoryInterval = "500ms"
}
if _, err = configDuration(cfg.HistoryInterval); err != nil {
return nil, fmt.Errorf("history_query_interval: %w", err)