mirror of
https://github.com/prometheus/prometheus
synced 2026-04-30 23:11:34 +08:00
Remove MaxConcurrent from the PromQL engine opts (#6712)
Since we use ActiveQueryTracker to check for concurrency in
d992c36b3a it does not make sense to keep
the MaxConcurrent value as an option of the PromQL engine.
This pull request removes it from the PromQL engine options, sets the
max concurrent metric to -1 if there is no active query tracker, and use
the value of the active query tracker otherwise.
It removes dead code and also will inform people who import the promql
package that we made that change, as it breaks the EngineOpts struct.
Signed-off-by: Julien Pivotto <roidelapluie@inuits.eu>
This commit is contained in:
committed by
Brian Brazil
parent
540dc7dfb0
commit
9adad8ad30
@@ -228,11 +228,10 @@ func (m rulesRetrieverMock) RuleGroups() []*rules.Group {
|
||||
defer storage.Close()
|
||||
|
||||
engineOpts := promql.EngineOpts{
|
||||
Logger: nil,
|
||||
Reg: nil,
|
||||
MaxConcurrent: 10,
|
||||
MaxSamples: 10,
|
||||
Timeout: 100 * time.Second,
|
||||
Logger: nil,
|
||||
Reg: nil,
|
||||
MaxSamples: 10,
|
||||
Timeout: 100 * time.Second,
|
||||
}
|
||||
|
||||
engine := promql.NewEngine(engineOpts)
|
||||
|
||||
Reference in New Issue
Block a user