Get/Set/Delete one value per file opening as few file descriptors as possible
var api = ;var api = ;api
I use this to keep track of a few key values each in it's own file. This package is not for caching lots of keys and is not fast. Its useful for tracking state to resume batch processing after a crash and optimized more for write than read.
- directory is the directory to store the key value files
- gets the value of a key
- sets a key to value
- deletes the key file and frees the file descritor
- closes the file descriptor and any pending actions for the key