https://github.com/simonwep/go-mini-kv
Miniature key-value database written in go
https://github.com/simonwep/go-mini-kv
database golang key-value key-value-store
Last synced: about 2 months ago
JSON representation
Miniature key-value database written in go
- Host: GitHub
- URL: https://github.com/simonwep/go-mini-kv
- Owner: simonwep
- License: mit
- Created: 2023-05-13T13:53:10.000Z (about 3 years ago)
- Default Branch: main
- Last Pushed: 2023-05-29T12:33:08.000Z (about 3 years ago)
- Last Synced: 2025-07-24T02:28:26.585Z (12 months ago)
- Topics: database, golang, key-value, key-value-store
- Language: Go
- Homepage:
- Size: 24.4 KB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
### Go Mini Key-Value Database
[](https://github.com/simonwep/go-mini-kv/actions/workflows/main.yml)
A miniature key-value database written in go, functions implemented so far include:
* `Open(loc tring)` - _Opens a new database, files are stored under the folder specified via `loc`._
* `Set(key []byte, value []byte) error` - _Sets a new value, the value is immediately written to the database._
* `Get(key []byte) ([]byte, error)` - _Retrieves a value from the database._
* `Stat() (*DataBaseStats, error)` - _Returns statistical information about the current database, such as the size and amount of entries._
* `RunGC() error` - _Runs the garbage collector, compressing both the dictionary and the data file._
Things that are not yet implemented:
* In-memory mode.
* Transactions.
* Backups.
...and many possible performance improvements.