pFad - Phone/Frame/Anonymizer/Declutterfier! Saves Data!


--- a PPN by Garber Painting Akron. With Image Size Reduction included!

URL: http://github.com/hyperdivision/tinybox

ithub.githubassets.com/assets/primer-70be7debc79a8eff.css" /> GitHub - hyperdivision/tinybox: Tiny, single file, scalable key value store based on HAMTs · GitHub
Skip to content

hyperdivision/tinybox

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

tinybox

Tiny, single file, scalable key value store based on HAMTs

npm install tinybox

Uses the Hypertrie trie without the replication parts, and auto compacts.

Still under development but the storage format should be stable. Upcoming features include batching, deletions and getting all values out of the store.

Usage

const TinyBox = require('tinybox')

const db = new TinyBox('./db')

db.put('hello', 'world', function () {
  db.get('hello', console.log)
})

API

db = new TinyBox(storage)

Create a new tiny store. Storage can be any random-access-storage instance. For conveinience you can pass a filename as storage as well.

db.get(key, callback)

Looks up a value. Key can be a buffer or string. If the key does not exist null is passed, otherwise the a Node object looking like this:

{
  key: <key as a buffer>,
  value: <value stored>
}

db.put(key, [value], [callback])

Insert a key and optional value.

License

MIT

About

Tiny, single file, scalable key value store based on HAMTs

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

pFad - Phonifier reborn

Pfad - The Proxy pFad © 2024 Your Company Name. All rights reserved.





Check this box to remove all script contents from the fetched content.



Check this box to remove all images from the fetched content.


Check this box to remove all CSS styles from the fetched content.


Check this box to keep images inefficiently compressed and original size.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy