Add metric query field to Canary CRD

This commit is contained in:
stefanprodan
2019-02-27 15:46:09 +02:00
parent 04a56a3591
commit d148933ab3
3 changed files with 9 additions and 3 deletions
+2
View File
@@ -100,6 +100,8 @@ spec:
pattern: "^[0-9]+(m|s)"
threshold:
type: number
query:
type: string
webhooks:
type: array
properties:
+2
View File
@@ -101,6 +101,8 @@ spec:
pattern: "^[0-9]+(m|s)"
threshold:
type: number
query:
type: string
webhooks:
type: array
properties:
+5 -3
View File
@@ -127,9 +127,11 @@ type CanaryAnalysis struct {
// CanaryMetric holds the reference to Istio metrics used for canary analysis
type CanaryMetric struct {
Name string `json:"name"`
Interval string `json:"interval"`
Threshold int `json:"threshold"`
Name string `json:"name"`
Interval string `json:"interval"`
Threshold float64 `json:"threshold"`
// +optional
Query string `json:"query,omitempty"`
}
// CanaryWebhook holds the reference to external checks used for canary analysis