Skip to content

New low-level streaming protobuf Riak client #213

@mikepb

Description

@mikepb

I was revisiting Riak's Protocol Buffer API and decided to use it to learn Node.JS's streaming API. I ended up using dcodeIO/ProtoBuf.js to write a nice stream-based "socket" for Riak:

https://github.com/mikepb/ripe-protobuf

var RipeSocket = require('ripe-protobuf');
var socket = new Ripe();

socket.write({
  type: 'RpbGetServerInfoReq'
});

socket.once('data', function (data) {
  console.log(data);
  // { type: 'RpbGetServerInfoResp',
  //   result: {
  //     node: 'riak@127.0.0.1',
  //     server_version: '2.0.0beta1' } }
});

This could be useful for #196 (this is a stream), #199 (uses Riak 2.0 .proto descriptions), #204 (underlying socket has keep-alive enabled), #210 (uses no native modules).

Would this library be useful to anyone?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions