We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
iosredis added the ssubscribe support https://github.com/luin/ioredis/pull/1690/files
but their API is ssubscribe rather than sSubscribe, same with the sPublish vs spublish.
ssubscribe
sSubscribe
sPublish
spublish
TypeError: this.subClient.sSubscribe is not a function
I believe we might need to have the workaround like this
const isRedisV4 = typeof this.pubClient.pSubscribe === "function"; if (isRedisV4) { this.redisListeners.set("psub", (msg, channel) => { this.onmessage(null, channel, msg); }); this.redisListeners.set("sub", (msg, channel) => { this.onrequest(channel, msg); }); this.subClient.pSubscribe( this.channel + "*", this.redisListeners.get("psub"), true ); this.subClient.subscribe( [ this.requestChannel, this.responseChannel, this.specificResponseChannel, ], this.redisListeners.get("sub"), true ); } else { this.redisListeners.set("pmessageBuffer", this.onmessage.bind(this)); this.redisListeners.set("messageBuffer", this.onrequest.bind(this)); this.subClient.psubscribe(this.channel + "*"); this.subClient.on( "pmessageBuffer", this.redisListeners.get("pmessageBuffer") ); this.subClient.subscribe([ this.requestChannel, this.responseChannel, this.specificResponseChannel, ]); this.subClient.on( "messageBuffer", this.redisListeners.get("messageBuffer") ); }
The text was updated successfully, but these errors were encountered:
fix(sharded): ensure compatibility with ioredis
42c8ab6
Related: #499
This should be fixed by 42c8ab6, included in release 8.2.1.
Please note that there seems to be an issue with the ssubscribe() command against a Redis cluster: redis/ioredis#1759
ssubscribe()
Sorry, something went wrong.
No branches or pull requests
iosredis added the ssubscribe support https://github.com/luin/ioredis/pull/1690/files
but their API is
ssubscribe
rather thansSubscribe
, same with thesPublish
vsspublish
.I believe we might need to have the workaround like this
The text was updated successfully, but these errors were encountered: