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

fix(array): unify hash function for datum and array #6209

Merged
merged 11 commits into from
Nov 4, 2022
Merged

Conversation

BugenZhao
Copy link
Member

@BugenZhao BugenZhao commented Nov 4, 2022

I hereby agree to the terms of the Singularity Data, Inc. Contributor License Agreement.

What's changed and what's your intention?

Unify the hash implementation into Scalar::hash_scalar. Also fix the implementation of the hash_at function for list and struct array.

Checklist

  • I have written necessary rustdoc comments
  • I have added necessary unit tests and integration tests
  • All checks passed in ./risedev check (or alias, ./risedev c)

Refer to a related PR or issue link (optional)

Signed-off-by: Bugen Zhao <i@bugenzhao.com>
Signed-off-by: Bugen Zhao <i@bugenzhao.com>
Signed-off-by: Bugen Zhao <i@bugenzhao.com>
Signed-off-by: Bugen Zhao <i@bugenzhao.com>
Signed-off-by: Bugen Zhao <i@bugenzhao.com>
@github-actions github-actions bot added the type/fix Bug fix label Nov 4, 2022
Signed-off-by: Bugen Zhao <i@bugenzhao.com>
Signed-off-by: Bugen Zhao <i@bugenzhao.com>
Signed-off-by: Bugen Zhao <i@bugenzhao.com>
@codecov
Copy link

codecov bot commented Nov 4, 2022

Codecov Report

Merging #6209 (df635ea) into main (f49b2d7) will decrease coverage by 0.07%.
The diff coverage is 57.87%.

@@            Coverage Diff             @@
##             main    #6209      +/-   ##
==========================================
- Coverage   74.25%   74.17%   -0.08%     
==========================================
  Files         940      944       +4     
  Lines      151208   152247    +1039     
==========================================
+ Hits       112272   112929     +657     
- Misses      38936    39318     +382     
Flag Coverage Δ
rust 74.17% <57.87%> (-0.08%) ⬇️

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

Impacted Files Coverage Δ
...batch/src/executor/join/distributed_lookup_join.rs 0.00% <0.00%> (ø)
src/batch/src/executor/join/mod.rs 73.17% <ø> (ø)
src/batch/src/executor/mod.rs 72.30% <ø> (ø)
src/batch/src/executor/utils.rs 33.33% <0.00%> (-23.81%) ⬇️
src/batch/src/task/channel.rs 57.69% <0.00%> (-7.53%) ⬇️
.../batch/src/task/consistent_hash_shuffle_channel.rs 0.00% <0.00%> (ø)
src/common/src/array/bool_array.rs 92.81% <ø> (-0.27%) ⬇️
src/common/src/array/decimal_array.rs 90.52% <ø> (-0.31%) ⬇️
src/common/src/array/primitive_array.rs 89.07% <ø> (+0.80%) ⬆️
src/common/src/array/utf8_array.rs 89.65% <ø> (-0.28%) ⬇️
... and 80 more

📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more

src/common/src/types/mod.rs Outdated Show resolved Hide resolved
Signed-off-by: Bugen Zhao <i@bugenzhao.com>
@mergify mergify bot merged commit 6652b67 into main Nov 4, 2022
@mergify mergify bot deleted the bz/unify-hash branch November 4, 2022 14:46
st1page pushed a commit that referenced this pull request Nov 16, 2022
* add hash_scalar

Signed-off-by: Bugen Zhao <i@bugenzhao.com>

* remove hash wrapper native

Signed-off-by: Bugen Zhao <i@bugenzhao.com>

* remove some hash_at

Signed-off-by: Bugen Zhao <i@bugenzhao.com>

* fix list / struct hash

Signed-off-by: Bugen Zhao <i@bugenzhao.com>

* use const

Signed-off-by: Bugen Zhao <i@bugenzhao.com>

* add unit test

Signed-off-by: Bugen Zhao <i@bugenzhao.com>

* add fixme

Signed-off-by: Bugen Zhao <i@bugenzhao.com>

* add issue

Signed-off-by: Bugen Zhao <i@bugenzhao.com>

Signed-off-by: Bugen Zhao <i@bugenzhao.com>
Co-authored-by: mergify[bot] <37929162+mergify[bot]@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type/fix Bug fix
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Hash implementation on Datum is not consistent with Array::hash_at
2 participants