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

index-gateway: fix index gateway chunk refs response #5957

Conversation

sandeepsukhani
Copy link
Contributor

@sandeepsukhani sandeepsukhani commented Apr 19, 2022

What this PR does / why we need it:
While building GetChunkRefs response from index gateways, we by mistake used the address of the loop variable. This causes us to have the same values for all the chunks. Lint somehow missed catching that mistake. This PR fixes the issue by using index for getting the address of the slice item.

@sandeepsukhani sandeepsukhani requested a review from a team as a code owner April 19, 2022 12:29
@chaudum
Copy link
Contributor

chaudum commented Apr 19, 2022

Great find! Do we have a test where we check the correctness of the chunk refs response?

@sandeepsukhani
Copy link
Contributor Author

Great find! Do we have a test where we check the correctness of the chunk refs response?

No, sorry, we don't have any such tests for index gateway. I just want to unblock our internal release for now. I won't be able to work on tests today. We can open an issue so that we don't forget adding them.

@sandeepsukhani
Copy link
Contributor Author

Here is the issue for tracking #5958

Copy link
Collaborator

@slim-bean slim-bean left a comment

Choose a reason for hiding this comment

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

LGTM!

@cyriltovena
Copy link
Contributor

Awesome I think we should have added a test too. If anyone want to take a stab at it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants