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

Introduce Comparator interface #88016

Merged
merged 4 commits into from
May 29, 2024
Merged

Introduce Comparator interface #88016

merged 4 commits into from
May 29, 2024

Conversation

leonorfmartins
Copy link
Contributor

What is this feature?

This PR introduces a comparator interface which will allow to compare returned objects from both stores and assert on its equality.
This comparator can later be called on each dualwriter and its result pushed to metrics (defined here)

Why do we need this feature?

[Add a description of the problem the feature is trying to solve.]

Who is this feature for?

[Add information on what kind of user the feature is for.]

Which issue(s) does this PR fix?:

Relates to https://github.com/grafana/search-and-storage-team/issues/37

Special notes for your reviewer:

Please check that:

  • It works as expected from a user's perspective.
  • If this is a pre-GA feature, it is behind a feature toggle.
  • The docs are updated, and if this is a notable improvement, it's added to our What's New doc.

@grafana-delivery-bot grafana-delivery-bot bot added this to the 11.1.x milestone May 17, 2024
@leonorfmartins leonorfmartins added the no-changelog Skip including change in changelog/release notes label May 17, 2024
@leonorfmartins leonorfmartins marked this pull request as ready for review May 17, 2024 19:37
@leonorfmartins leonorfmartins requested a review from a team as a code owner May 17, 2024 19:37
@diegommm
Copy link
Contributor

LGTM, some tests are failing though.

@suntala
Copy link
Contributor

suntala commented May 21, 2024

LGTM as well. Was there any discussion about what we might want to return? For instance, returning some kind of struct which provides a full accounting of which fields were a match and which ones were not?

@leonorfmartins leonorfmartins merged commit ade96db into main May 29, 2024
13 checks passed
@leonorfmartins leonorfmartins deleted the dualwriter/comparator branch May 29, 2024 07:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/backend no-changelog Skip including change in changelog/release notes
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants