level-http2
v0.0.4
Published
Access a leveldb instance via HTTP2
Downloads
23
Readme
level-http2
Access a leveldb instance via HTTP2
Client
var levelHTTP2= require('level-http2');
var db= levelHTTP2.client('http://127.0.0.1:8080/');
// db is a normal level-up api
db.put('mykey','myvalue',function (err,value)
{
db.get('mykey',function (err,value)
{
console.log(err, value);
});
});
Server (embedded)
var levelHTTP2= require('level-http2');
levelHTTP2.server({ path: './data' }).listen(8080);
Server (cli)
$ level-http2 --path ./data --port 8080