Giter Club home page Giter Club logo

sharedb-redis-pubsub's Introduction

sharedb-redis-pubsub

NPM Version Build Status Coverage Status

Redis pub/sub adapter adapter for ShareDB.

This ShareDB add-on gives you horizontal scalability; the ability to have a cluster of multiple server nodes rather than just a single server. Using this adapter, clients can connect to any machine in your cluster, and the ops they submit will be forwarded clients connected through other nodes, and there will be no race conditions with regard to persistence.

Usage

This snippet shows how to load this library and pass it into a new ShareDB instance.

// Redis client is an existing redis client connection
var redisPubsub = require('sharedb-redis-pubsub')({client: redisClient});

var backend = new ShareDB({
  db: db,  // db would be your mongo db or other storage location
  pubsub: redisPubsub
});

sharedb-redis-pubsub's People

Contributors

alecgibson avatar avital avatar craigbeck avatar curran avatar dcharbonnier avatar ericyhwang avatar nateps avatar rkstedman avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

sharedb-redis-pubsub's Issues

Basic project documentation

I'm looking into ShareDB and it is not clear what the function of this project is. It would be good to have documentation which includes things like:

  • What is the pub/sub system which this library is built for?
  • Why would you use this Redis library over the default memory one?
  • Are there any disadvantages of using this library?

node-redis v3 Support

The sharedb-redis-pubsub package.json lists redis v2.6 as a dependency.

The node-redis library is now at version 3. Here's their list of breaking changes:

  • Dropped support for Node.js < 6
  • Dropped support for hiredis (no longer required)
  • Removed previously deprecated drain event
  • Removed previously deprecated idle event
  • Removed previously deprecated parser option
  • Removed previously deprecated max_delay option
  • Removed previously deprecated max_attempts option
  • Removed previously deprecated socket_no_delay option

It sounds like this should be compatible with our usage of the Redis library? We should potentially bump this in the package.json like we did for sharedb-mongo

Missing license

Npm says it's MIT. Could you please add the corresponding license file? Thanks!

Support `redis` v4

The redis library release a massive breaking change in v4, which โ€” amongst other things โ€” redefines how a client is instantiated.

They have a (small) migration guide.

We should probably discuss the best way to add support for this version whilst maintaining backwards compatibility with previous versions.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.