Skip to content
New issue

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

SUBSCRIBE in an asynchronous context #17

Closed
nicolasff opened this issue Dec 26, 2010 · 2 comments
Closed

SUBSCRIBE in an asynchronous context #17

nicolasff opened this issue Dec 26, 2010 · 2 comments

Comments

@nicolasff
Copy link
Contributor

Hello,

I've tried to use the SUBSCRIBE command with an asynchronous adapter, but it doesn't seem to be supported.
The main problem is with the __redisPushCallback, __redisShiftCallback functions: the SUBSCRIBE command first sends a message confirming the subscription to the channel, which consumes the redisCallback object. A write to the channel will try to shift the next redisCallback object, which doesn't exist: this leads to an assertion failure in async.c:217.

I have tried to re-add the redisCallback by making __redisPushCallback public instead of static. This seems to work, but I don't think I should be calling this private function.

What do you think? Is there a better way to do this?

@ghost
Copy link

ghost commented Apr 20, 2011

I'm having the same issue with the MONITOR command. I want to asynchronously monitor multiple servers.

@nicolasff
Copy link
Contributor Author

Oh, I hadn't realised this issue was still open, it has been fixed for about 4 months now. @Tomy you need to open a connection per server, there's no way around it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant