github.com/argoproj/argo-cd@v1.8.7/resource_customizations/argoproj.io/AnalysisRun/testdata/errorAnalysisRunWithStatusMessage.yaml (about)

     1  apiVersion: argoproj.io/v1alpha1
     2  kind: AnalysisRun
     3  metadata:
     4    name: canary-demo-analysis-template-6c6bb7cf6f-btpgc
     5    namespace: default
     6  spec:
     7    analysisSpec:
     8      metrics:
     9        - failureCondition: result < 92
    10          interval: 10
    11          name: memory-usage
    12          provider:
    13            prometheus:
    14              address: 'http://prometheus-operator-prometheus.prometheus-operator:9090'
    15              query: >
    16                sum(rate(nginx_ingress_controller_requests{ingress="canary-demo-preview",status!~"[4-5].*"}[2m]))
    17                /
    18                sum(rate(nginx_ingress_controller_requests{ingress="canary-demo-preview"}[2m]))
    19          successCondition: result > 95
    20  status:
    21    message: "Status Message: Assessed as Error"
    22    metricResults:
    23      - consecutiveError: 5
    24        error: 5
    25        measurements:
    26          - finishedAt: '2019-10-28T18:13:01Z'
    27            startedAt: '2019-10-28T18:13:01Z'
    28            phase: Error
    29            value: '[0.9832775919732442]'
    30          - finishedAt: '2019-10-28T18:13:11Z'
    31            startedAt: '2019-10-28T18:13:11Z'
    32            phase: Error
    33            value: '[0.9832775919732442]'
    34          - finishedAt: '2019-10-28T18:13:21Z'
    35            startedAt: '2019-10-28T18:13:21Z'
    36            phase: Error
    37            value: '[0.9722530521642618]'
    38          - finishedAt: '2019-10-28T18:13:31Z'
    39            startedAt: '2019-10-28T18:13:31Z'
    40            phase: Error
    41            value: '[0.9722530521642618]'
    42          - finishedAt: '2019-10-28T18:13:41Z'
    43            startedAt: '2019-10-28T18:13:41Z'
    44            phase: Error
    45            value: '[0.9722530521642618]'
    46        name: memory-usage
    47        phase: Error
    48    phase: Error