Yakety
Bi-directional node to node messaging and request-reply.
Both the server and client can send and receive messages as well as requests-replys.
Yakety is a bit like a RESTful service, but allows the server to instigate requests to the client, plus fire-and-forget messages. Yakety will also maintain persistent connections by automatically reconnecting clients. Yakety is for back-end node to node communications, not a browser compatible solution.
Installation
npm install yakety
Examples
See examples folder.
Server example
const yakety = ; var options = protocol: 'ws' // or 'wss' for secure. slowHandshake: true // true: can do your own authorization and handshake or close socket. port: 8080; var server = ; server; // auth clients:server; server;
Client example
const yakety = ; var options = protocol: 'ws' // or 'wss' for secure. hostname: '127.0.0.1' port: 8080 path: '/foo/bar/?hello=world' auth: 'username:password'; var client = ; client; client; client; client; client; client;
Test
npm test
Notes
Yakety is built on top of these open protocols: naked-websocket for TCP/TLS network link and SMP for message framing, with any payload codec: String, Buffer, JSON, MsgPack, etc.
License
Choose either: MIT or Apache 2.0.