laravel-echo-server
laravel-echo-server copied to clipboard
allowing multiple nodes using socket.io-redis
At the moment laravel-echo-server can run in single instance mode because it 's using the default in-memory adapter which means whispers won't be propagated across nodes.
Here are the changes that make it possible to run multiple nodes.
- Added socket.io-redis as an adapter when redis db is set
- Modified the redis-subscriber to ignore all messages coming from the adapter
- Modified the echo-server to broadcasts to local connections only to avoid sending multiple events due to the new adapter behavior.
Thanks for the PR will be checking it out soon. I need to spend some time on refactoring the docs to be more readable. Once that is ready this will be available in 1.4.1 or later
I have laravel-echo-server
deployed on Google App Engine, with autoscaling. I'm occasionally losing connections, and getting a lot of 400
responses indicating that the session ID is invalid.
I'm assuming this lack of multi-instance support is the issue, and that if this change were merged, it would fix my problem.
I know this is over two years old now, and has merge conflicts, but is there any chance this could get looked at again, and maybe merged in?
I think, this multiple node support is important. Do you need help to review this one @tlaverdure ?
I would also really appreciate this being considered again, any conflicts fixed, and merged.
@tlaverdure what is the current status of this? Do you need help reviewing and testing it?
Bump
Any update?
@tlaverdure what's the current state here?
@tlaverdure any update here plz?