Questions tagged [socket.io-redis]

Adapter to enable broadcasting of events to multiple separate socket.io server nodes.

By running socket.io with the socket.io-redis adapter you can run multiple socket.io instances in different processes or servers that can all broadcast and emit events to and from each other.

If you need to emit events to socket.io instances from a non-socket.io process, you should use socket.io-emitter.

See also

Installing:

$ npm install socket.io
112 questions
0
votes
1 answer

socket.io-redis keeps throwing NOAUTH error

I am trying to connect to my redis server that password protected but for some reason I keep getting the error: events.js:141 throw er; // Unhandled 'error' event ^ ReplyError: Ready check failed: NOAUTH Authentication required. at…
Shawn Varughese
  • 450
  • 4
  • 17
0
votes
1 answer

How to send data from client to only socket server

I know that if I emit data on a socket, the data would be emitted to the all connected clients. io.emit("test", data) For instance if I run the command above, actually the data reaches to the all clients. But only test channel listeners handle…
efkan
  • 12,991
  • 6
  • 73
  • 106
0
votes
1 answer

use socketio and redis on multiple servers

I'm trying to use socketio on multiple servers, during a whole week I tried different solution, on different platform and all of them are not working. for my project I'm using nginx load balancing with iphash to keep the clients on the same server,…
Bilel Boulifa
  • 216
  • 2
  • 5
0
votes
1 answer

Using socket.io-redis on azure web service

Currently I have deployed a node application to azure app service. My current app service plan has two core processor. And I have set nodeProcessCountPerApplication: 2 in iisnode.yml file. Now I have implemented socket.io functionality for real time…
Anup Das Gupta
  • 772
  • 1
  • 7
  • 24
0
votes
1 answer

socket.io client not receiving io.emit from server ( using redis adapter )

I have a problem which started when updated to 1.4.5 recently. ( This has been working for the last 2 years ) . So when I send a client-msg to the server, the server receives the msg and then is supposed to emit the msg back to all the connected…
Squivo
  • 917
  • 1
  • 10
  • 21
0
votes
2 answers

How can i synchronize the total number of socket.io client in both server in node js

I am using node js 4.2.6 version and using 1.4.5 socket.io version.I am using socket.io-redis module as the adaptor for socket.io. I am having two server with port 3000 and 4000. I added timer to print total number of connection sockets as…
Soorya Prakash
  • 921
  • 3
  • 9
  • 29
0
votes
0 answers

EC2 Socket Connection

I tried to use socket.io with EC2 and laravel. Here's my code in server side - server.js var app = require('express')(); var server = require('http').Server(app); var io = require('socket.io')(server); var redis =…
0
votes
1 answer

Storing socket.io emits in global array + Node.js

Is there a way to store all emits of socket.io in a global array so that I can loop through the emits when a new user joins the website and can pickup where the 'canvas drawing' currently is. I want the new user to see what work has already been…
Arihant
  • 3,847
  • 16
  • 55
  • 86
0
votes
2 answers

Can't access to a specfic field in JSON, saying undefined in javascript

I have a project in Laravel + socket.io , I need to access a specific field in the json being broadcasted. Here is the code. socket.js redis.on('message', function(channel, message) { message = JSON.parse(message); io.emit(channel + ':' +…
lonestar
  • 377
  • 1
  • 7
  • 16
0
votes
1 answer

Mutliple nodejs server communicating with each other with socket.io-redis not receiving event

I managed to connect two nodejs server to Redis using socket.io-redis. Using "redis-cli monitor" I can see events being received on Redis butit dosent go all the way. It is like I'm missing something. here how both server look like (with the numbers…
0
votes
4 answers

Node JS Socket.IO Emitter (and redis)

I'll give a small premise of what I'm trying to do. I have a game concept in mind which requires multiple players sitting around a table somewhat like poker. The normal interaction between different players is easy to handle via socket.io in…
0
votes
1 answer

Multiplayer game server with multiple node

Say you're making a Counter-Strike server. We have a single lobby and multiple rooms in which game sessions occur. I.E I have 3 node server, nginx load balancer, redis. SCHEMA I'm using socket.io, with redis adapter, So I can emit messages to every…
0
votes
1 answer

Do I need to close my Redis connection?

Using ioredis. I'm not using the redis.disconnect() but recently I got a: Ready check failed: ERR max number of clients reached error. Does this has to do with me not closing?
Bob van Luijt
  • 7,153
  • 12
  • 58
  • 101
0
votes
2 answers

Socket.io redis How data stored and cleared

i am hosting an app on heroku which is using socket.io. it is using sockets and i am using heroku 4 standard 1X dynos . So for this i used redistogo service and socket.io-redis plugin. it's working great but i want to know does socket.io-redis also…
mathlearner
  • 7,509
  • 31
  • 126
  • 189
0
votes
2 answers

socket.io-redis giving error on heroku

i am trying to deploy my app on heroku.i added redistogo addon in my app.it is based on node.js and express. i write a small code var redis = require('socket.io-redis'); var io =…
mathlearner
  • 7,509
  • 31
  • 126
  • 189