https://github.com/codepr/sls
Simple Bitcask implementation using GenServer.
https://github.com/codepr/sls
Last synced: 5 months ago
JSON representation
Simple Bitcask implementation using GenServer.
- Host: GitHub
- URL: https://github.com/codepr/sls
- Owner: codepr
- Created: 2022-11-20T19:49:22.000Z (over 3 years ago)
- Default Branch: main
- Last Pushed: 2025-01-19T23:25:55.000Z (over 1 year ago)
- Last Synced: 2025-01-20T00:25:47.038Z (over 1 year ago)
- Language: Elixir
- Homepage:
- Size: 34.2 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Sls
Simple [Bitcask](https://riak.com/assets/bitcask-intro.pdf) implementation using
`GenServer`.
The key benefits are:
- Low latency per item read or written
- Consistent performance
- Handles datasets larger than RAM
- Small design specification
The main drawback is:
- All your keys must fit in RAM
GenServers are used to both write and read to the datafiles, using a single
GenServer process to write and multiple GenServers to read. The in-memory
index is based on the `ets` cache.
## Installation
If [available in Hex](https://hex.pm/docs/publish), the package can be installed
by adding `sls` to your list of dependencies in `mix.exs`:
```elixir
def deps do
[
{:sls, "~> 0.1.0"}
]
end
```
Documentation can be generated with [ExDoc](https://github.com/elixir-lang/ex_doc)
and published on [HexDocs](https://hexdocs.pm). Once published, the docs can
be found at .