Alerting: update rules POST API to validate query and condition only for rules that changed. (#68667)
* replace condition validation with just structural validation * validate conditions of only new and updated rules * add integration tests for rule update\delete API Co-authored-by: George Robinson <george.robinson@grafana.com>
This commit is contained in:
co-authored by
George Robinson
parent
94881597d8
commit
b963defa44
@@ -55,9 +55,6 @@ func (srv TestingApiSrv) RouteTestGrafanaRuleConfig(c *contextmodel.ReqContext,
|
||||
UID: body.NamespaceUID,
|
||||
Title: body.NamespaceTitle,
|
||||
},
|
||||
func(condition ngmodels.Condition) error {
|
||||
return srv.evaluator.Validate(eval.NewContext(c.Req.Context(), c.SignedInUser), condition)
|
||||
},
|
||||
srv.cfg,
|
||||
)
|
||||
if err != nil {
|
||||
|
||||
Reference in New Issue
Block a user