primus - :zap: Primus, the creator god of the transformers & an abstraction layer for real-time to prevent module lock-in

  •        84

Primus, the creator god of transformers but now also known as universal wrapper for real-time frameworks. There are a lot of real-time frameworks available for Node.js and they all have different opinions on how real-time should be done. Primus provides a common low level interface to communicate in real-time using various real-time frameworks.If you deploy your application behind a reverse proxy (Nginx, HAProxy, etc.) you might need to add WebSocket specific settings to its configuration files. If you intend to use WebSockets, please ensure that these settings have been added. There are some example configuration files available in the observing/balancerbattle repository.

http://primus.io
https://github.com/primus/primus

Dependencies:

access-control : ~1.0.0
asyncemit : ~3.0.1
create-server : ~1.0.1
diagnostics : ~1.1.0
eventemitter3 : ~3.0.0
forwarded-for : ~1.0.1
fusing : ~1.0.0
setheader : ~0.0.4
ultron : ~1.1.0
yeast : ~0.1.2

Tags
Implementation
License
Platform

   




Related Projects

Atmosphere - Realtime Client Server Framework for the JVM

  •    Java

The Atmosphere Framework contains client and server side components for building Asynchronous Web Applications. It transparently supports WebSockets, Server Sent Events (SSE), Long-Polling, HTTP Streaming (Forever frame) and JSONP. Its mission is to make real time apps possible in every browser, library and mobile device, blurring the differences between the different transport mechanisms.

ClusterWS - :boom: Lightweight, fast and powerful framework for building scalable WebSocket applications in Node

  •    TypeScript

Lightweight, fast and powerful framework for building scalable WebSocket applications in Node.js. ClusterWS uses uWebSockets - one of the most lightweight, efficient & scalable WebSocket library.

faye-websocket-node - Standards-compliant WebSocket client and server

  •    Javascript

This is a general-purpose WebSocket implementation extracted from the Faye project. It provides classes for easily building WebSocket servers and clients in Node. It does not provide a server itself, but rather makes it easy to handle WebSocket connections within an existing Node application. It does not provide any abstraction other than the standard WebSocket API. It also provides an abstraction for handling EventSource connections, which are one-way connections that allow the server to push data to the client. They are based on streaming HTTP responses and can be easier to access via proxies than WebSockets.

socket.io - Realtime application framework (Node.JS server)

  •    Javascript

For this purpose, it relies on Engine.IO, which first establishes a long-polling connection, then tries to upgrade to better transports that are "tested" on the side, like WebSocket. Please see the Goals section for more information. Unless instructed otherwise a disconnected client will try to reconnect forever, until the server is available again. Please see the available reconnection options here.

ember-websockets - EmberJS WebSockets and Socket.IO addon

  •    Javascript

The send method takes 2 arguments. A message which is passed into the native websockets send method and an optional stringify boolean. This boolean, if set to true, will do a JSON.stringify to the message before passing it to the websocket send method. If you are sending strings it is recommended to pass true. socketFor takes two arguments: a url, a protocol array (optional), and returns a socket instance from its cache or a new websocket connection if one was not found.


wsify - Just a tiny, simple and real-time self-hosted pub/sub messaging service

  •    Go

I wanted to create a tiny solution that can replace pusher and similar services and learning more about the realtime world, so I dispatched this project.

nchan - Fast, horizontally scalable, multiprocess pub/sub queuing server and proxy for HTTP, long-polling, Websockets and EventSource (SSE), powered by Nginx

  •    C

Nchan is a scalable, flexible pub/sub server for the modern web, built as a module for the Nginx web server. It can be configured as a standalone server, or as a shim between your application and hundreds, thousands, or millions of live subscribers. It can buffer messages in memory, on-disk, or via Redis. All connections are handled asynchronously and distributed among any number of worker processes. It can also scale to many Nginx servers with Redis. Messages are published to channels with HTTP POST requests or Websocket, and subscribed also through Websocket, long-polling, EventSource (SSE), old-fashioned interval polling, and more.

node-browserchannel - An implementation of a google browserchannel server in node.js

  •    CoffeeScript

tldr; Its like socket.io, but it scales better and it has fewer bugs. It just does long polling. It also doesn't support websockets and doesn't support cross-domain requests out of the box. Note: Websocket support is now reasonably universal. Strongly consider using raw websockets for new projects.

Beaver - 💨A real time messaging server to build a scalable in-app notifications, multiplayer games, chat apps in web and mobile apps

  •    Go

A Real Time Messaging Server. Beaver is a real-time messaging server. With beaver you can easily build scalable in-app notifications, realtime graphs, multiplayer games, chat applications, geotracking and more in web applications and mobile apps.

WebSocket-Node - A WebSocket Implementation for Node.JS (Draft -08 through the final RFC 6455)

  •    Javascript

This is a (mostly) pure JavaScript implementation of the WebSocket protocol versions 8 and 13 for Node. There are some example client and server applications that implement various interoperability testing protocols in the "test/scripts" folder. For a WebSocket client written in ActionScript 3, see my AS3WebScocket project.

faye-websocket-ruby - Standards-compliant WebSocket client and server

  •    Ruby

This is a general-purpose WebSocket implementation extracted from the Faye project. It provides classes for easily building WebSocket servers and clients in Ruby. It does not provide a server itself, but rather makes it easy to handle WebSocket connections within an existing Rack application. It does not provide any abstraction other than the standard WebSocket API. It also provides an abstraction for handling EventSource connections, which are one-way connections that allow the server to push data to the client. They are based on streaming HTTP responses and can be easier to access via proxies than WebSockets.

pushpin - Reverse proxy for realtime web services

  •    C++

Pushpin is a reverse proxy server written in C++ that makes it easy to implement WebSocket, HTTP streaming, and HTTP long-polling services. The project is unique among realtime push solutions in that it is designed to address the needs of API creators. Pushpin is transparent to clients and integrates easily into an API stack. To assist with integration, there are libraries for many backend languages and frameworks. Pushpin has no libraries on the client side because it is transparent to clients.

socketcluster - Highly scalable realtime framework

  •    Javascript

SocketCluster is a fast, highly scalable HTTP + realtime server engine which lets you build multi-process realtime servers that make use of all CPU cores on a machine/instance. It removes the limitations of having to run your Node.js server as a single thread and makes your backend resilient by automatically recovering from worker crashes and aggregating errors into a central log on each host. SC can also auto-scale across multiple hosts on top of Kubernetes; see SCC guide: https://github.com/SocketCluster/socketcluster/blob/master/scc-guide.md.There are two ways to install SocketCluster.

private_pub - Handle pub/sub messaging through private channels in Rails using Faye.

  •    Ruby

Private Pub is a Ruby gem for use with Rails to publish and subscribe to messages through Faye. It allows you to easily provide real-time updates through an open socket without tying up a Rails process. All channels are private so users can only listen to events you subscribe them to. Watch RailsCasts Episode 316 for a demonstration of Private Pub.

angular-socket-io-seed - A great starting point for writing AngularJS apps backed by a Socket

  •    Javascript

Start an awesome app with AngularJS on the front, Socket.io + Express + Node on the back. This project is an application skeleton for writing AngularJS apps that use web sockets to add real-time functionality. If you're not planning on using web sockets, you should consider the Angular Express Seed instead.The seed contains angular libraries, test libraries and a bunch of scripts all preconfigured for instant web development gratification. Just clone the repo (or download the zip/tarball) and you're ready to develop your application.

iodine - iodine - HTTP / Websocket Server with Pub/Sub support, optimized for Ruby MRI on Linux / BSD

  •    C

Iodine is ideal for Linux/Unix based systems (i.e. macOS, Ubuntu, FreeBSD etc'), which are ideal for evented IO (while Windows and Solaris are better at IO completion events, which are totally different). Iodine is a C extension for Ruby, developed and optimized for Ruby MRI 2.2.2 and up... it should support the whole Ruby 2.0 MRI family, but Rack requires Ruby 2.2.2, and so iodine matches this requirement.

flask-sockets - Elegant WebSockets for your Flask apps.

  •    Python

Elegant WebSockets for your Flask apps. Combining WebSockets with Ajax (XHR) endpoints also comes handy with the support of session handling built-in to sockets as well. As an example you could use an Ajax login call which would create a new session and accordingly set a secure HttpOnly cookie to the browser. After authorization, you can connect to the WebSocket endpoint and reuse the session handling from Flask there as well (as shown here: https://pythonhosted.org/Flask-Session/). Access to other custom cookies is also possible via Flasks request.cookies property.