Skip to content

BTree issues #58

@heniotierra

Description

@heniotierra

Hi,

I think I have found a few problems with the BTree implementation.

  1. Not sure if this is really a problem, but the same key can be inserted multiple times;

  2. If the same key is inserted more than M-1 times, there will be a split, and only the M/2 keys of the new node will be accessible, while the other ones will be forever inaccessible;

  3. When a slipt occurs, the old node keeps the keys that were sent to the new node, even though they now inaccessible in that node; again, this may not be a problem;

  4. When a key is removed, the method still increments the size counter, instead of decreasing it;

Since I am using the this BTree implementation, I have fixed these problems on my side.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions