Create A Levelup Proxy to Riak
Riak is a clustered key-value database that applies "AP" from the CAP Theorem. It has HTTP and Protocol Buffers APIs, but can be a little bit cumbersome to browse keys for debugging. I've been getting used to hij1nx's lev for debugging levelup and thought it would be handy to use the same tool for Riak.
$ level2riak --bucket somebucket Connected to riak://localhost:8087/somebucket Listening for multilevel connection on: 8091
Now just load lev and save connection details to match the proxy.
You can also use lev's other modes: cli and repl.
But wait, there's more!
I turned this into an npm package.
npm install --global level2riak
You can then run it with:
level2riak --bucket somebucket
As of this writing, I've made an update to lev, ~~but I'm waiting on hij1nx to publish to npm~~. The manifest is no longer required, repl can handle remote connections, and I added --conns and --use for listing and using preconfigured connections.