yjs / y-redis

Alternative backend for y-websocket
GNU Affero General Public License v3.0
173 stars 39 forks source link

switch to io-redis to be able to work with redis-sentinel #28

Closed Loki-Afro closed 1 month ago

Loki-Afro commented 1 month ago

Checklist

[ ] Are you reporting a bug? Use github issues for bug reports and feature requests. For general questions, please use https://discuss.yjs.dev/ [ ] Try to report your issue in the correct repository. Yjs consists of many modules. When in doubt, report it to https://github.com/yjs/yjs/issues/

Is your feature request related to a problem? Please describe. A clear and concise description of what the problem is. Ex. I'm always frustrated when [...] We want to run redis as a cluster using sentinel as far as i know only the io-redis library supports redis sentinel, it also has a retry mechanism which i'm keen to use

Describe the solution you'd like A clear and concise description of what you want to happen. use io-redis instead of basic redis library

Describe alternatives you've considered none

Loki-Afro commented 1 month ago

i'm / we are happy to create a pr @dmonad would you be okay with that?

Loki-Afro commented 1 month ago

hey @dmonad we replaced node-redis with io-redis in order to get it work with redis sentinel or valkey for that matter.

we would be happy to create a pr with this along some other changes (probably in separate prs)

you can have a look here: https://github.com/hpi-schul-cloud/y-redis/tree/io-redis

dmonad commented 1 month ago

Both projects are now owned by Redis. I suspect that ioredis will eventually phase out of existence, so I want to stick with node-redis for now.

I hear that node-redis has a branch / beta release that supports sentinel. So support will land eventually.

Loki-Afro commented 1 month ago

@dmonad true, we think that as well, but it took them ages, and based on that speed it will take even longer ;)