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

Query: Fix exemplarsServer data race (#4777) #4805

Merged
merged 2 commits into from
Oct 28, 2021

Conversation

hanjm
Copy link
Member

@hanjm hanjm commented Oct 28, 2021

Fix #4777.

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

Changes

  1. write a unit test, go test -race to reproduce it .
  2. add sync.Mutex to *exemplarsServer.

Verification

  1. go test -race
  2. deploy it at Production, monitor log.

Signed-off-by: Jimmiehan <hanjinming@outlook.com>
@hanjm hanjm changed the title Query: fix exemplarsServer data race (#4777) Query: Fix exemplarsServer data race (#4777) Oct 28, 2021
@hanjm hanjm force-pushed the fix/jimmiehan-fix-warnings-data-race branch from 27c6178 to 0805393 Compare October 28, 2021 08:15
Signed-off-by: Jimmiehan <hanjinming@outlook.com>
@hanjm hanjm force-pushed the fix/jimmiehan-fix-warnings-data-race branch from 0805393 to 3a5450f Compare October 28, 2021 08:30
@hanjm hanjm mentioned this pull request Oct 28, 2021
2 tasks
Copy link
Member

@GiedriusS GiedriusS left a comment

Choose a reason for hiding this comment

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

Thank you, I think a similar fix might be needed for metadata/targets/rules proxies?

@GiedriusS GiedriusS merged commit 9856576 into thanos-io:main Oct 28, 2021
@hanjm
Copy link
Member Author

hanjm commented Oct 29, 2021

Thank you, I think a similar fix might be needed for metadata/targets/rules proxies?

👍 You are right, let me fix it.

@hanjm hanjm deleted the fix/jimmiehan-fix-warnings-data-race branch October 29, 2021 02:23
akanshat pushed a commit to akanshat/thanos that referenced this pull request Oct 30, 2021
* Query: add exemplarsServer data race test (thanos-io#4777)

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

* Query: fix exemplarsServer data race (thanos-io#4777)

Signed-off-by: Jimmiehan <hanjinming@outlook.com>
@hanjm hanjm mentioned this pull request Nov 30, 2021
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.

Query: panic on api.Respond warn.Error()
2 participants