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
Implementation of Binary B-Tree #9709
Merged
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Additional assertions.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
What does this PR do?
Implementation of B+Tree which contains keys represented as arrays of bytes.
Those arrays of bytes are keys normalized by the rules which allow preserving lexicographic order of keys using comparison of byte arrays without conversion to original keys.
This B+Tree also implements prefix and suffix compression.
Motivation
The major reason why this tree was implemented is performance improvements both for the cases when all data are placed in memory and partially placed on disk. Compression allows to decrease the size of the index on disk and as a result, increases the speed of IO operations and binary presentation of keys increases the speed of processing of data.
Because CollatorKeys are used to convert string keys, this implementation also fixes collation problems in indexes.
Related issues
#3899 #8698
Additional Notes
This is the implementation of the B+Tree itself, actual integration into system will be done later.
Checklist
[x] I have run the build using
mvn clean package
command[x] My unit tests cover both failure and success scenarios