Skip to content

fix /api/v1/rules value#1872

Merged
bwplotka merged 1 commit intothanos-io:masterfrom
yeya24:fix-rule
Dec 11, 2019
Merged

fix /api/v1/rules value#1872
bwplotka merged 1 commit intothanos-io:masterfrom
yeya24:fix-rule

Conversation

@yeya24
Copy link
Copy Markdown
Contributor

@yeya24 yeya24 commented Dec 11, 2019

Signed-off-by: yeya24 yb532204897@gmail.com

  • I added CHANGELOG entry for this change.
  • Change is not relevant to the end user.

Changes

Ref: prometheus/prometheus#5582

Verification

curl localhost:10906/api/v1/rules | jq
{
  "status": "success",
  "data": {
    "groups": [
      {
        "name": "test-alert-group",
        "file": "valid.yaml",
        "rules": [
          {
            "name": "test",
            "query": "1",
            "duration": 0,
            "labels": {
              "key": "value"
            },
            "annotations": {
              "key": "value"
            },
            "alerts": [
              {
                "labels": {
                  "alertname": "test",
                  "key": "value"
                },
                "annotations": {
                  "key": "value"
                },
                "state": "firing",
                "activeAt": "2019-12-11T10:07:10.851171763-05:00",
                "value": "1e+00",
                "partial_response_strategy": "WARN"
              }
            ],
            "health": "ok",
            "type": "alerting",
            "partial_response_strategy": "WARN"
          }
        ],
        "interval": 5,
        "partial_response_strategy": "WARN"
      }
    ]
  }
}

Signed-off-by: yeya24 <yb532204897@gmail.com>
Copy link
Copy Markdown
Member

@bwplotka bwplotka left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks!

@bwplotka bwplotka merged commit 4506fb1 into thanos-io:master Dec 11, 2019
@yeya24 yeya24 deleted the fix-rule branch December 11, 2019 19:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants