nitishm / go-rejson

Golang client for redislabs' ReJSON module with support for multilple redis clients (redigo, go-redis)

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Remove direct dependency of clients for obtaining connection

Shivam010 opened this issue · comments

go-redis provides 4 different types of protocols to connect to Redis

Similarly, Redigo provides a single method:

And as we only use Do method of both the clients. Hence, in order to support these different types of connections in each client, abstracting the required method is the only feasible option

Originally posted by @Shivam010 in #62 (comment)

Just FYI I'm leaving 53 for now since it looks like you are covering that here. I have a copy working with ClusterClient if you ever decide you need it. Once I get approval I can push the branch for reference.

Yeah, firstly thanks @jaysonhurd for your contribution. Secondly, I don't think we're gonna need that anymore. Cause with the use of interface as a connection, one can use any connection type, it just needs to implement the corresponding Do method.

@Shivam010 Tested it and it works great with our ClusterClient connection. Thanks!!