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

refactor: KeyValues return ValueRef #2170

Merged

Conversation

v0y4g3r
Copy link
Contributor

@v0y4g3r v0y4g3r commented Aug 14, 2023

I hereby agree to the terms of the GreptimeDB CLA

What's changed and what's your intention?

Returns a ValueRef in KeyValue's primary_key/field/timestamp method to avoid a clone.

Checklist

  • I have written the necessary rustdoc comments.
  • I have added the necessary unit tests and integration tests.

Refer to a related PR or issue link (optional)

@v0y4g3r v0y4g3r requested a review from evenyag August 14, 2023 08:40
src/datatypes/src/value.rs Outdated Show resolved Hide resolved
2. Replace OpType/SemanticType with pb's OpType and SemanticType to avoid duplicated conversions.
@v0y4g3r v0y4g3r requested a review from evenyag August 14, 2023 14:25
@codecov
Copy link

codecov bot commented Aug 14, 2023

Codecov Report

Merging #2170 (138687d) into develop (b353bd2) will decrease coverage by 0.43%.
Report is 2 commits behind head on develop.
The diff coverage is 29.56%.

❗ Current head 138687d differs from pull request most recent head 449cf32. Consider uploading reports for the commit 449cf32 to get more accurate results

@@             Coverage Diff             @@
##           develop    #2170      +/-   ##
===========================================
- Coverage    85.04%   84.62%   -0.43%     
===========================================
  Files          698      696       -2     
  Lines       111711   111738      +27     
===========================================
- Hits         95008    94557     -451     
- Misses       16703    17181     +478     

@v0y4g3r v0y4g3r requested a review from evenyag August 14, 2023 14:37
@v0y4g3r v0y4g3r enabled auto-merge August 14, 2023 14:40
@v0y4g3r v0y4g3r added this pull request to the merge queue Aug 14, 2023
Merged via the queue into GreptimeTeam:develop with commit e924b44 Aug 14, 2023
12 checks passed
@v0y4g3r v0y4g3r deleted the refactor/key-value-use-value-ref branch August 14, 2023 15:03
paomian pushed a commit to paomian/greptimedb that referenced this pull request Oct 19, 2023
* refactor: KeyValues return ValueRef

* 1. Change KeyValues returned value from pb value to ValueRef
2. Replace OpType/SemanticType with pb's OpType and SemanticType to avoid duplicated conversions.

* feat: define min value of OpType as a const

* fix: toml format
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.

3 participants