Update CRD with req duration metric

This commit is contained in:
Stefan Prodan
2018-09-28 13:28:12 +03:00
parent 7c96e8b081
commit 5adbcd5189
8 changed files with 98 additions and 45 deletions
+15 -4
View File
@@ -1,4 +1,7 @@
# monitor events: watch "kubectl -n test describe rollout/podinfo | sed -n 35,1000p"
# run tester: kubectl run -n test tester --image=quay.io/stefanprodan/podinfo:1.2.1 -- ./podinfo --port=9898
# generate latency: watch curl http://podinfo-canary:9898/delay/1
# generate errors: watch curl http://podinfo-canary:9898/status/500
apiVersion: apps.weave.works/v1beta1
kind: Rollout
metadata:
@@ -17,9 +20,17 @@ spec:
host: podinfo-canary
virtualService:
name: podinfo
# canary increment step
# percentage (0-100)
weight: 10
metric:
type: counter
name: istio_requests_total
interval: 1m
metrics:
- name: istio_requests_total
# minimum req success rate (non 5xx responses)
# percentage (0-100)
threshold: 99
interval: 1m
- name: istio_request_duration_seconds_bucket
# maximum req duration P99
# milliseconds
threshold: 500
interval: 1m
+12 -10
View File
@@ -43,14 +43,16 @@ spec:
type: string
weight:
type: number
metric:
metrics:
type: array
properties:
type:
type: string
name:
type: string
interval:
type: string
pattern: "^[0-9]+(m)"
threshold:
type: number
items:
type: object
properties:
name:
type: string
interval:
type: string
pattern: "^[0-9]+(m)"
threshold:
type: number
+1 -1
View File
@@ -22,7 +22,7 @@ spec:
serviceAccountName: steerer
containers:
- name: steerer
image: stefanprodan/steerer:0.0.1-beta.5
image: stefanprodan/steerer:0.0.1-beta.9
imagePullPolicy: Always
ports:
- name: http