4ib3r / StompBrokerJS

NodeJS StompBroker
MIT License
36 stars 28 forks source link

StompBrokerJS

NodeJS StompBroker

This is simple NodeJs STOMP 1.1 broker for embedded usage.

build state Support

Features

TODO

Changelog

Example

var http = require("http");
var StompServer = require('stomp-broker-js');

var server = http.createServer();
var stompServer = new StompServer({server: server});

server.listen(61614);

stompServer.subscribe("/**", function(msg, headers) {
  var topic = headers.destination;
  console.log(topic, "->", msg);
});

stompServer.send('/test', {}, 'testMsg');

Documentation

https://4ib3r.github.io/StompBrokerJS/