Jump to content

bombe93

Members
  • Content Count

    31
  • Joined

  • Last visited

  1. Ok i tried but but with your changes gives me this error (client side): WebSocket connection to 'ws://serverip:9520/socket.io/?EIO=3&transport=websocket&sid=YcKquHdjmXK1_nLoAAAA' failed: Connection closed before receiving a handshake response
  2. I tried but gives me an error: Cannot find module 'socket.io/lib/sores/redis'. I think you are using an older version of socket.io.
  3. Ok. yes it seems to work perfectly! I tried with your changes but gives me an error: http://s23.postimg.org/tixearg3f/Cattura2.png I think that the module "redis" there isn't in the socket.io but there is this: https://www.npmjs.com/package/socket.io-redis
  4. Ok but without 'ent' gives me this error (i think javascript or socket.io) https://github.com/Automattic/socket.io/issues/1989 I used this https://github.com/evilstudios/chat-example-cluster/blob/master/index.js There was an error with cluster.
  5. Ok it all works but I have a problem. Passing an object as a variable( example pickInfo) in the server side gives me an error(using ent.encode(objet). Without ent.encode() gives me this error(maybe javascript/socket.io): https://github.com/Automattic/socket.io/issues/1989 if anyone knows what is wrong or if there's another way to pass objects let me know, thanks.
  6. I used the address of the server instead of localhost because the client files are run on another PC that is not the server. (40.50.60.20 is only an expample of server ip instead of localhost) ---------------------------------- Maybe is a problem with Cluster? (https://github.com/Unitech/pm2/issues/81) RedisStore is a bit different (https://github.com/Automattic/socket.io/wiki/Migrating-to-1.0#redisstore-changes) -------------------------------- it seems that I have solved: https://github.com/evilstudios/chat-example-cluster
  7. For example, even if I do not open the web page where run the ws command sometimes appears to me also "Connected to worker: 2". I believe that it should not do it if I do not open the page, right? --------------------------- Yes, but i always use not localhost but the ip of the server and the port like 40.50.60.20:8520 is right?
  8. Ok, i run in 8520 port. I tried several times and it seems that sometimes connects and sometimes it fails. I can't understand what is the problem
  9. Yes socket.io is installed. I checked if the port is open with the site (http://www.yougetsignal.com/tools/open-ports/) and it results open.
  10. Yes i installed redis (sudo apt-get install redis-server). If i write redis-server in command line this is the response (http://s15.postimg.org/kjrj6zosr/image.png). The path "RedisStore = require('socket.io/lib/stores/redis')," gives me an error (http://s9.postimg.org/d9lam45n3/image.png). Therefore i installed "npm install socket.io-redis --save" and changed this code: RedisStore = require('socket.io/lib/stores/redis'), redis = require('socket.io/node_modules/redis'); in this:RedisStore = require('socket.io-redis'), redis = require('redis'); but gives me this error: "
  11. I have a problem: RedisStore = require('socket.io/lib/stores/redis'),redis = require('socket.io/node_modules/redis'); RedisStore does not exist. I installed redis but the path is "root/node_modules/redis". Why use the path socket.io? This is the right solution? (http://stackoverflow.com/questions/23952640/migrating-socket-io-from-0-9-x-to-1-x-problems-with-configuring-redisstore) --------------------Returns many times this error "WebSocket connection to 'ws://MyIp:8520/socket.io/?EIO=3&transport=websocket&sid=HsbslLeePELkFMehAAAA' failed: Connection closed before receiving a h
×
×
  • Create New...