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

Move Archive test into shared integration test suite #5207

Merged
merged 54 commits into from
Mar 29, 2024

Conversation

Wise-Wizard
Copy link
Contributor

Which problem is this PR solving?

This PR addresses the issue #5203

Description of the changes
This PR addresses the issue #5203 by integrating the testArchiveTrace function into the common StorageIntegration type. This modification ensures compatibility with multiple storage backends, allowing the archiving test to be executed across different environments.

How was this change tested?

The changes were tested by running the following command:

make test

Checklist

  • I have read CONTRIBUTING_GUIDELINES.md
  • I have signed all commits
  • I have added unit tests for the new functionality
  • I have run lint and test steps successfully
    • for jaeger: make lint test
    • for jaeger-ui: yarn lint and yarn test

Signed-off-by: Wise-Wizard <saransh.shankar@gmail.com>
@Wise-Wizard Wise-Wizard requested a review from a team as a code owner February 16, 2024 17:18
plugin/storage/integration/integration.go Outdated Show resolved Hide resolved
plugin/storage/integration/integration.go Outdated Show resolved Hide resolved
plugin/storage/integration/integration.go Outdated Show resolved Hide resolved
plugin/storage/integration/integration.go Outdated Show resolved Hide resolved
Signed-off-by: Wise-Wizard <saransh.shankar@gmail.com>
Signed-off-by: Wise-Wizard <saransh.shankar@gmail.com>
Copy link

codecov bot commented Feb 18, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 95.09%. Comparing base (2285143) to head (effeb3a).

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #5207      +/-   ##
==========================================
+ Coverage   95.06%   95.09%   +0.03%     
==========================================
  Files         340      340              
  Lines       16628    16652      +24     
==========================================
+ Hits        15808    15836      +28     
+ Misses        630      624       -6     
- Partials      190      192       +2     
Flag Coverage Δ
badger 13.28% <20.83%> (+0.02%) ⬆️
cassandra-3.x 26.42% <20.83%> (-0.03%) ⬇️
cassandra-4.x 26.42% <20.83%> (-0.03%) ⬇️
elasticsearch-5.x 22.08% <91.66%> (+0.39%) ⬆️
elasticsearch-6.x 22.07% <91.66%> (+0.36%) ⬆️
elasticsearch-7.x 22.17% <91.66%> (+0.39%) ⬆️
elasticsearch-8.x 22.23% <91.66%> (+0.36%) ⬆️
grpc 11.54% <91.66%> (+0.55%) ⬆️
kafka 14.67% <0.00%> (-0.06%) ⬇️
opensearch-1.x 22.17% <91.66%> (+0.39%) ⬆️
opensearch-2.x 22.15% <91.66%> (+0.36%) ⬆️
unittests 92.27% <91.66%> (+0.02%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Copy link
Member

@yurishkuro yurishkuro left a comment

Choose a reason for hiding this comment

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

there should not be submodule changes in this PR

plugin/storage/integration/integration.go Outdated Show resolved Hide resolved
plugin/storage/integration/integration.go Outdated Show resolved Hide resolved
@Wise-Wizard
Copy link
Contributor Author

there should not be submodule changes in this PR

Yeah, actually before making any changes at all. In the main branch after executing git pull, the submodule showed M (Modified) icon automatically. So, I thought those changes were coming from git pull itself?

Signed-off-by: Wise-Wizard <saransh.shankar@gmail.com>
Signed-off-by: Wise-Wizard <saransh.shankar@gmail.com>
@yurishkuro yurishkuro added the changelog:test Change that's adding missing tests or correcting existing tests label Feb 19, 2024
@yurishkuro
Copy link
Member

there should not be submodule changes in this PR

You can do this:

git checkout main
git pull 
git submodule update --recursive
git checkout pr-branch
git commit -sm 'fix submodules'

Your main branch must be up to date with upstream.

Wise-Wizard and others added 2 commits February 19, 2024 23:48
Co-authored-by: Yuri Shkuro <yurishkuro@users.noreply.github.com>
Signed-off-by: Saransh Shankar <103821431+Wise-Wizard@users.noreply.github.com>
Signed-off-by: Wise-Wizard <saransh.shankar@gmail.com>
Copy link
Member

@yurishkuro yurishkuro left a comment

Choose a reason for hiding this comment

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

where is the "extract" part of this PR? The ES storage integration test still contains archive logic.

plugin/storage/integration/integration.go Outdated Show resolved Hide resolved
@Wise-Wizard
Copy link
Contributor Author

where is the "extract" part of this PR? The ES storage integration test still contains archive logic.

Yes, I am yet to remove the archive logic from ES Storage Integration. Thought will do that after the logic is approved.

@Wise-Wizard
Copy link
Contributor Author

Hi, @yurishkuro. I had a query regarding this issue. You mentioned that the archive span reader/writer is not being ued. But, in the existing code of elasticsearch_test.go, the archive trace test is using the same Span Reader/Writer received from integration.go field. So, is that wrong itself?
Screenshot 2024-03-21 213816

@Wise-Wizard
Copy link
Contributor Author

Hi, @yurishkuro. I had a query regarding this issue. You mentioned that the archive span reader/writer is not being ued. But, in the existing code of elasticsearch_test.go, the archive trace test is using the same Span Reader/Writer received from integration.go field. So, is that wrong itself? Screenshot 2024-03-21 213816

Why can't I just extract this to integration.go, and add a condition to check if the specific storage supports archiving and then only execute the test?

@yurishkuro
Copy link
Member

Why can't I just extract this to integration.go, and add a condition to check if the specific storage supports archiving and then only execute the test?

That was exactly the objective of the ticket, but it's not what your PR is doing. "extract" means "move", not duplicate.

This reverts commit a6b83b2.

Signed-off-by: Wise-Wizard <saransh.shankar@gmail.com>
Signed-off-by: Wise-Wizard <saransh.shankar@gmail.com>
This reverts commit a6b83b2.

Signed-off-by: Wise-Wizard <saransh.shankar@gmail.com>
Signed-off-by: Wise-Wizard <saransh.shankar@gmail.com>
Signed-off-by: Wise-Wizard <saransh.shankar@gmail.com>
Signed-off-by: Wise-Wizard <saransh.shankar@gmail.com>
Wise-Wizard and others added 5 commits March 29, 2024 09:53
Co-authored-by: Yuri Shkuro <yurishkuro@users.noreply.github.com>
Signed-off-by: Saransh Shankar <103821431+Wise-Wizard@users.noreply.github.com>
Signed-off-by: Wise-Wizard <saransh.shankar@gmail.com>
Signed-off-by: Wise-Wizard <saransh.shankar@gmail.com>
Signed-off-by: Wise-Wizard <saransh.shankar@gmail.com>
Wise-Wizard and others added 3 commits March 29, 2024 11:06
Signed-off-by: Wise-Wizard <saransh.shankar@gmail.com>
Signed-off-by: Wise-Wizard <saransh.shankar@gmail.com>
Wise-Wizard and others added 2 commits March 29, 2024 21:58
Co-authored-by: Yuri Shkuro <yurishkuro@users.noreply.github.com>
Signed-off-by: Saransh Shankar <103821431+Wise-Wizard@users.noreply.github.com>
Signed-off-by: Wise-Wizard <saransh.shankar@gmail.com>
@yurishkuro yurishkuro changed the title Extracted Archive Test Move Archive test into shared integration test suite Mar 29, 2024
@yurishkuro yurishkuro merged commit f934846 into jaegertracing:main Mar 29, 2024
37 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
changelog:test Change that's adding missing tests or correcting existing tests
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants