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

Add RedisModule adapter #1182

Merged
merged 2 commits into from
Apr 24, 2023
Merged

Add RedisModule adapter #1182

merged 2 commits into from
Apr 24, 2023

Conversation

tezc
Copy link
Contributor

@tezc tezc commented Apr 17, 2023

Starting from this commit: redis/redis#10001, redis (v7.0+) exposes its event loop from the module API.
This PR adds an adapter to attach hiredis to redis' event loop. By doing that, a redis module can send commands to other redis instances via async hiredis.

@tezc
Copy link
Contributor Author

tezc commented Apr 17, 2023

I just realize there is also scheduleTimer callback. We were using the adapter without it, I completely missed it. I'll implement it and then update the PR.

examples/example-redismoduleapi.c Show resolved Hide resolved
examples/example-redismoduleapi.c Outdated Show resolved Hide resolved
@yossigo yossigo requested a review from michael-grunder April 24, 2023 08:35
@michael-grunder michael-grunder merged commit 3fa9b69 into redis:master Apr 24, 2023
@michael-grunder
Copy link
Collaborator

Merged. This is great, thanks.

@tezc tezc deleted the module-adapter branch April 27, 2023 10:07
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

Successfully merging this pull request may close these issues.

3 participants