Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Endpointset: Do not use info client to obtain metadata (for now) #4714

Merged

Conversation

matej-g
Copy link
Collaborator

@matej-g matej-g commented Sep 30, 2021

Signed-off-by: Matej Gera matejgera@gmail.com

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

Changes

In #4699 it was discovered that users might be receiving 'false' reports due to increase in number of Unimplemented error, caused by attempting to obtain metadata via gRPC service, which is not yet implemented.

The fix proposed here is to remove info client for now and instead always fall back to using store API to obtain metadata. After #4282 we should be able to switch back to using info client.

The PR also adjusts the tests accordingly and fixes some discrepancies (e.g. the mocked rule component was not exposing store API)

Resolves #4699

Verification

Updated tests.

Signed-off-by: Matej Gera <matejgera@gmail.com>
Signed-off-by: Matej Gera <matejgera@gmail.com>
Copy link
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! One nit only.

@@ -10,6 +10,10 @@ We use *breaking :warning:* to mark changes that are not backward compatible (re

## Unreleased

### Fixed
Copy link
Member

Choose a reason for hiding this comment

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

👍🏽

metadata, merr := es.getMetadataUsingStoreAPI(ctx, client.store)
if merr != nil {
return nil, errors.Wrapf(merr, "fallback fetching info from %s after err: %v", es.addr, err)
if client.info != nil {
Copy link
Member

Choose a reason for hiding this comment

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

I would add the same comment here otherwise readers will be surprised. OR just remove the whole client.info

Copy link
Member

Choose a reason for hiding this comment

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

(We can get it back from git)

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

You're right, without having the context it's surprising. I'll add the same comment to keep it consistent.

Signed-off-by: Matej Gera <matejgera@gmail.com>
Signed-off-by: Matej Gera <matejgera@gmail.com>
@matej-g
Copy link
Collaborator Author

matej-g commented Sep 30, 2021

If anyone could re-run just the failed flow on for CircleCI test, I believe it's a flaky test (see #3798 (comment)) and not a real failure. Thanks.

@bwplotka bwplotka merged commit f7f7061 into thanos-io:release-0.23 Sep 30, 2021
@bwplotka
Copy link
Member

Giving up.

bwplotka added a commit that referenced this pull request Oct 6, 2021
* Cut release 0.23.0-rc.0 (#4625)

Signed-off-by: Bartlomiej Plotka <bwplotka@gmail.com>

* Updated version.

Signed-off-by: Bartlomiej Plotka <bwplotka@gmail.com>

* Cut 0.23.0-rc.1 and cherry picked 3 critical commits from main. (#4684)

* Sidecar: Fix process external label on promethues v2.28+ use units.Bytes config type (#4657)

* Sidecar: Fix process external label when promethues v2.28+ use units.Bytes config type (#4656)

Signed-off-by: hanjm <hanjinming@outlook.com>

* E2E: Upgrade prometheus image version

Signed-off-by: hanjm <hanjinming@outlook.com>

* upgrade Prometheus dependency version to v2.30.0 (#4669)

* upgrade Prometheus dependency version to v2.30.0

Signed-off-by: Ben Ye <ben.ye@bytedance.com>

* fix unit test

Signed-off-by: Ben Ye <ben.ye@bytedance.com>
# Conflicts:
#	go.mod
#	go.sum

* Query: Fix (*exemplarsStream).receive/(*metricMetadataStream).receive/(*targetsStreamStream).receive infinite loop when target response Unimplemented error (#4676) (#4681)

Signed-off-by: hanjm <hanjinming@outlook.com>

* Cut 0.23.0-rc.1

Signed-off-by: Bartlomiej Plotka <bwplotka@gmail.com>

Co-authored-by: Jimmiehan <hanjinming@outlook.com>
Co-authored-by: Ben Ye <yb532204897@gmail.com>

* Cut 0.23.0 release. (#4697)

* Endpointset: Do not use info client to obtain metadata (for now) (#4714)

* Do not use info client to obtain metadata

Signed-off-by: Matej Gera <matejgera@gmail.com>

* Update CHANGELOG.

Signed-off-by: Matej Gera <matejgera@gmail.com>

* Comment out client.info usage

Signed-off-by: Matej Gera <matejgera@gmail.com>

* Fix lint error

Signed-off-by: Matej Gera <matejgera@gmail.com>

* Cutting 0.23.1 (#4718)

Signed-off-by: Bartlomiej Plotka <bwplotka@gmail.com>

* Moved tutorials Thanos versions to 0.23.1

Signed-off-by: Bartlomiej Plotka <bwplotka@gmail.com>

* Added volounteer for shepharding, fixed VERSION.

Signed-off-by: Bartlomiej Plotka <bwplotka@gmail.com>

Co-authored-by: Jimmiehan <hanjinming@outlook.com>
Co-authored-by: Ben Ye <yb532204897@gmail.com>
Co-authored-by: Matej Gera <38492574+matej-g@users.noreply.github.com>
@sherifkayad
Copy link

@matej-g @bwplotka I guess this fix hasn't made it to v0.24, has it? .. I am still seeing the issue there

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.

None yet

3 participants