-
Notifications
You must be signed in to change notification settings - Fork 4
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: Tree filled lower than order is not searchable #13
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
anuragvohraec
changed the title
Fixed issue: Tree filled lower than order.
Fixed issue: Tree filled lower than order is not searchable
May 13, 2020
Alex-Werner
changed the title
Fixed issue: Tree filled lower than order is not searchable
fix: Tree filled lower than order is not searchable
May 15, 2020
Alex-Werner
pushed a commit
that referenced
this pull request
May 15, 2020
Alex-Werner
added a commit
that referenced
this pull request
May 15, 2020
…14) * fix: issue with lower fill factor than order for single element tree (#13) * fix(SBFRoot/findLowerThan): finding document on equal case for lte Specific case when order is bigger than actual size * style: formatting * test: add tests for tree with lower size than order Co-authored-by: Anurag Vohra <53807480+anuragvohraec@users.noreply.github.com>
Alex-Werner
added a commit
that referenced
this pull request
Aug 29, 2020
* chore: update mongo-objectid + exposed it (#16) * chore: updated mongo-objectid to 1.2.0 * feat: exposed ObjectID * test: added exposition test * chore: updated mongo-objectid to 1.2.1 * chore: bump dependencies to latest fix security issue. * fix: consistency issue with getDocument on unfound doc (#15) Match fs adapter comportment * chore(package): bump to 3.0.0 * fix: issue with lower fill factor than order for single element tree (#14) * fix: issue with lower fill factor than order for single element tree (#13) * fix(SBFRoot/findLowerThan): finding document on equal case for lte Specific case when order is bigger than actual size * style: formatting * test: add tests for tree with lower size than order Co-authored-by: Anurag Vohra <53807480+anuragvohraec@users.noreply.github.com> * docs: docsify Co-authored-by: Anurag Vohra <53807480+anuragvohraec@users.noreply.github.com>
Alex-Werner
added a commit
that referenced
this pull request
Aug 29, 2020
* chore: update mongo-objectid + exposed it (#16) * chore: updated mongo-objectid to 1.2.0 * feat: exposed ObjectID * test: added exposition test * chore: updated mongo-objectid to 1.2.1 * chore: bump dependencies to latest fix security issue. * fix: consistency issue with getDocument on unfound doc (#15) Match fs adapter comportment * chore(package): bump to 3.0.0 * fix: issue with lower fill factor than order for single element tree (#14) * fix: issue with lower fill factor than order for single element tree (#13) * fix(SBFRoot/findLowerThan): finding document on equal case for lte Specific case when order is bigger than actual size * style: formatting * test: add tests for tree with lower size than order Co-authored-by: Anurag Vohra <53807480+anuragvohraec@users.noreply.github.com> * feat: add isReady method + remove waitFor deps (#18) * feat(SBTree): add isReady method * feat: moved waitFor to use isReady method * fix: fslock breaking change * docs: docsify documentation (#22) * chore: update mongo-objectid + exposed it (#16) * chore: updated mongo-objectid to 1.2.0 * feat: exposed ObjectID * test: added exposition test * chore: updated mongo-objectid to 1.2.1 * chore: bump dependencies to latest fix security issue. * fix: consistency issue with getDocument on unfound doc (#15) Match fs adapter comportment * chore(package): bump to 3.0.0 * fix: issue with lower fill factor than order for single element tree (#14) * fix: issue with lower fill factor than order for single element tree (#13) * fix(SBFRoot/findLowerThan): finding document on equal case for lte Specific case when order is bigger than actual size * style: formatting * test: add tests for tree with lower size than order Co-authored-by: Anurag Vohra <53807480+anuragvohraec@users.noreply.github.com> * docs: docsify Co-authored-by: Anurag Vohra <53807480+anuragvohraec@users.noreply.github.com> * tests!: reorganize tests + nested functional BREAKING: get document unfound returns null instead of {} * chore: added DS and nyc output to ignored entities * chore!: return single document as [] + split lodash module * chore: update dev deps * style: eslint fix * fix: handling on unfound field * feat!: remove single object as array * chore: add badges Co-authored-by: Anurag Vohra <53807480+anuragvohraec@users.noreply.github.com>
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.
Issue being fixed or implemented
As of now if the tree is filled less then order size, one cannot search/delete/replace documents if using $lte to query. Example code:
In above code, we create a tree with order size three and filled it with only one elements.
Now if we delete the document using query `{ts: {$lte:t1}} , the single documents though valid for deletio is not found out and deleted/
What was done
The problem seems to be occuring due to leafIndex incrementation below order level.
Have applied a decrement operation to balance the mismatch.
How Has This Been Tested?
Have re-run the sample code, which failed.
Notes
Checklist: