/bltree-go-for-embedding

Golang implementation of b-link tree container usable in your DBMS project

Primary LanguageGoOtherNOASSERTION

test

blink-tree-go for embedding

Customized Point

  • (adding of a method for range scan)
  • blink-tree-go has own buffer manager
  • But if you want to use blink-tree-go on your DBMS project, you should want to use your buffer manager for memory management
  • For realization of memory management with your buffer manager, bltree-go-for-embedding integrates buffer manager of blink-tree-go and one of yours
    • Buffer manager (BufMgr) of bltree-go-for-embedding treat your buffer manager as some storage or something which offers persistence
  • You need only to implement ParentBufMgr interface and ParentPage interface
  • Then you only pass the object of ParentBufMgr interface implemented class to factory function of BufMgr and create BLTree object with it

Note

  • You need allocate fixed amount of pages to BufMgr of bltree-go-for-embedding, unfortunately your buffer manager can't page out all of pages which are used by bltree-go-for-embedding
    • The amount can be specified at call of factory function of BufMgr
  • Page size can be specified in same manner with bits of page size
    • ex: 12 bits means 2^12 bytes (4096 bytes)
  • Max size of key is 200bytes and sizes of all keys should be same
    • Causes of this restriction are some bugs on concurrent access
    • Without this restriction, this lib rarely crashes though works collectly on almost of all situation

Usage example