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

Implement Equal() for map-valued AttributeValues #3612

Merged
merged 2 commits into from Jul 14, 2021

Conversation

punya
Copy link
Member

@punya punya commented Jul 13, 2021

Description

The implementation AttributeValue.Equals() was incomplete, because it didn't handle values that were of map (kvlist) type. This PR handles that case.

Link to tracking Issue

Possibly #2488.

Testing:

Added to the existing unit test.

Resolves a TODO in the implementation
@punya punya requested a review from a team as a code owner July 13, 2021 21:32
@punya punya requested a review from owais July 13, 2021 21:32
@bogdandrutu
Copy link
Member

@punya please fix lint errors:

pdata/common.go:290:4: shadow: declaration of "av" shadows declaration at line 263 (govet)
			av := newAttributeValue(&vv[i])
			^
make[2]: *** [../Makefile.Common:26: lint] Error 1

@punya
Copy link
Member Author

punya commented Jul 14, 2021

@bogdandrutu I'm happy to fix it, but please note that the new declaration as well as the one it shadows are on lines outside of my change.

@bogdandrutu
Copy link
Member

@punya not going to fight with the tools :))

@bogdandrutu bogdandrutu merged commit 071268f into open-telemetry:main Jul 14, 2021
@punya punya deleted the pdata-attributevalue-map-equal branch July 14, 2021 19:10
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

4 participants