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

feat: impl memtable and memtable iterator #46

Merged
merged 2 commits into from
Mar 15, 2022
Merged

feat: impl memtable and memtable iterator #46

merged 2 commits into from
Mar 15, 2022

Conversation

MrCroxx
Copy link
Owner

@MrCroxx MrCroxx commented Mar 15, 2022

Danger: unsafe impl Send + Sync for Node (read_only + atomic) and IterRef (inner always Sync + Send). Check twice!!!

  • Implement Memtable and MemtableIterator.
  • Fix Comparator::same_key.
  • Fix timestamp encoding, bug: use big end encoding for timestamp #47 .
  • Fix MemtableIterator handle multi version and tombstone.
  • Add unit tests for MemtableIterator.
  • Add concurrent unit tests for Memtable.

Ref: #44 .
Close: #47 .

@MrCroxx MrCroxx added the feature New feature. label Mar 15, 2022
@MrCroxx MrCroxx self-assigned this Mar 15, 2022
@codecov-commenter
Copy link

Codecov Report

Merging #46 (f2fb3e9) into main (97bc5c6) will increase coverage by 0.77%.
The diff coverage is 93.18%.

Impacted file tree graph

@@            Coverage Diff             @@
##             main      #46      +/-   ##
==========================================
+ Coverage   89.56%   90.33%   +0.77%     
==========================================
  Files          26       28       +2     
  Lines        2433     2555     +122     
==========================================
+ Hits         2179     2308     +129     
+ Misses        254      247       -7     
Impacted Files Coverage Δ
storage/src/lsm_tree/iterator/mod.rs 66.66% <ø> (ø)
storage/src/lsm_tree/utils/skiplist/list.rs 72.90% <ø> (+13.54%) ⬆️
storage/src/lsm_tree/components/memtable.rs 70.58% <70.58%> (ø)
rudder/src/meta.rs 10.34% <75.00%> (-72.99%) ⬇️
storage/src/lsm_tree/iterator/memtable_iterator.rs 97.16% <97.16%> (ø)
storage/src/lsm_tree/iterator/sstable_iterator.rs 93.36% <100.00%> (ø)
storage/src/lsm_tree/utils/skiplist/arena.rs 92.85% <0.00%> (+7.14%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 97bc5c6...f2fb3e9. Read the comment docs.

- Fix `Comparator::same_key`.
- Fix timestamp encoding, #47 .
- Fix `MemtableIterator` handle multi version and tombstone.
- Add unit tests for `MemtableIterator`.
- Add concurrent unit tests for `Memtable`.
@MrCroxx MrCroxx enabled auto-merge (squash) March 15, 2022 14:09
@MrCroxx MrCroxx merged commit 09c72a4 into main Mar 15, 2022
@MrCroxx MrCroxx deleted the xx/memtable branch March 15, 2022 14:14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature New feature.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

bug: use big end encoding for timestamp
2 participants