HomePhabricator

rules: fix silly mistakes in the rules API (#2957)

Authored by Giedrius Statkevičius <giedriuswork@gmail.com> on Aug 11 2020, 6:50 AM.

Description

rules: fix silly mistakes in the rules API (#2957)

  • rules: fix silly mistakes in the rules API

Fixes https://github.com/thanos-io/thanos/issues/2938 and is a follow up
to https://github.com/thanos-io/thanos/pull/2925.

Changes:

  • Copying all fields properly to the group-level as well
  • Set TZ to UTC explicitly in other time.Time fields to avoid a panic
  • Make sure that RuleGroup always has an empty array in the rules

field because that's customary and that is what the new React UI
expects.

Manual testing for now.

Signed-off-by: Giedrius Statkevičius <giedriuswork@gmail.com>

  • rules: remove DeprecatedPartialResponseStrategy

It has been marked deprecated for more than 2 months. Remove it finally.

Signed-off-by: Giedrius Statkevičius <giedriuswork@gmail.com>

  • e2e: rules_api: add checks for non-zero values

Signed-off-by: Giedrius Statkevičius <giedriuswork@gmail.com>

  • test: e2e: fix rule test

Signed-off-by: Giedrius Statkevičius <giedriuswork@gmail.com>

  • test: rule: fix govet error

Signed-off-by: Giedrius Statkevičius <giedriuswork@gmail.com>

  • Update CHANGELOG.md

Signed-off-by: Giedrius Statkevičius <giedriuswork@gmail.com>

Co-authored-by: Lucas Servén Marín <lserven@gmail.com>

  • Update CHANGELOG.md

Signed-off-by: Giedrius Statkevičius <giedriuswork@gmail.com>

Co-authored-by: Lucas Servén Marín <lserven@gmail.com>

Co-authored-by: Lucas Servén Marín <lserven@gmail.com>

Details

Committed
GitHub <noreply@github.com>Aug 11 2020, 6:50 AM
Parents
rODTH626f248362fe: receive,ruler: Upgraded TSDB and used ChunkIterator in Series TSDB Store.
Branches
Unknown
Tags
Unknown
ChangeId
None

Event Timeline

GitHub <noreply@github.com> committed rODTH600318dce52d: rules: fix silly mistakes in the rules API (#2957) (authored by Giedrius Statkevičius <giedriuswork@gmail.com>).Aug 11 2020, 6:50 AM