Redis uri standardization

405 views
Skip to first unread message

Dinesh Kumar

unread,
Sep 26, 2017, 9:14:10 AM9/26/17
to Redis DB
 Hello,

I would like to know if there is any standard format for uri  (for single node setup, mulit-node setup : i.e. redis with sentinel nodes) defined by redis (community) which can be then followed by various client libraries. In that case, it would be easy to expose redis as a service using this standard uri, which in turn can be then consumed by applications using clients like jedis, lettuce etc.

I did some basic search but couldn't find any common uri definition valid across client libraries. Thank you !

Regards,
Dinesh


Itamar Haber

unread,
Sep 26, 2017, 9:37:23 AM9/26/17
to Redis DB
Hello Dinesh,

AFAIK the only semi-formal standard is at https://www.iana.org/assignments/uri-schemes/prov/redis.

That said, different clients have different uri parsing abilities so you have to read up on the one that you're using in order to implement it correctly.

--
You received this message because you are subscribed to the Google Groups "Redis DB" group.
To unsubscribe from this group and stop receiving emails from it, send an email to redis-db+unsubscribe@googlegroups.com.
To post to this group, send email to redi...@googlegroups.com.
Visit this group at https://groups.google.com/group/redis-db.
For more options, visit https://groups.google.com/d/optout.



--

Itamar Haber | Chief OSS Education Officer
Redis Labs ~/redis

Mobile: +972 (54) 567 9692
Twitter: @itamarhaber
Skype: itamar.haber

Dinesh Kumar

unread,
Sep 26, 2017, 9:52:53 AM9/26/17
to redi...@googlegroups.com
Hello,

Thanks for the pointer. It is very helpful. The standard outlines single-node format but I don't see any information on sentinels (multi-node format).

I understand that different clients have (and can parse) uri in different ways. I'm looking for a standardization so that "redis as a service" (exposed by any PAAS platform) can be consumed by different applications using different clients without any changes to redis service since all of these clients will understand the standard uri format / specification.

For instance, lettuce-core came up with the following uri details. 


If a standard is adopted then redis (when exposed as a service) can be ignorant about the clients. I hope my intend is clear.

Regards,
Dinesh

Itamar Haber

unread,
Sep 26, 2017, 11:23:18 AM9/26/17
to Redis DB
I see what you mean - Lettuce's URI "extensions" are indeed a nice touch.

Personally, I prefer providing multiple nodes as a collection/list/whatever instead of a complexified uri. As for sentinel, it being variant of a Redis server, I'm not convinced about requiring a different uri scheme. I guess it is a matter of taste and probably more - I glad you brought it up and hope it will generate some discussion.

Cheers, 

Dinesh Kumar

unread,
Sep 27, 2017, 5:05:34 AM9/27/17
to redi...@googlegroups.com
Yes, even I feel that sentinel, being a variant of a Redis server, can go in the redis uri scheme. That being said, unless we propose a standard around this, client libraries will go ahead and create their own specifications (like redis-sentinel by lettuce), which may lead to a less ideal scenario for redis users.

@Itamar, What according to you needs to be done to append existing redis IANA documents to cover sentinels and other formats ?

Regards,
Dinesh

Mark Paluch

unread,
Sep 27, 2017, 5:36:03 AM9/27/17
to Redis DB
The majority of use cases is handled via redis and rediss schemes which is perfectly fine for Redis Standalone, even a simple Master/Slave setup.

It would make sense to agree whether representing Redis Sentinel and Redis Cluster endpoints as connection string (connection URI) is something we want to define. From a user's perspective, it's quite common to configure endpoints using a URI/connection string, from an implementor perspective, that's additional complexity which is added to the library. I see it also as part of standardization how to configure a Redis client.

There aren't many samples of multi-host connection strings. In the open source world, MongoDB [0] might be one of the more popular data stores with such an approach.

Cheers, 
Mark

To unsubscribe from this group and stop receiving emails from it, send an email to redis-db+u...@googlegroups.com.

To post to this group, send email to redi...@googlegroups.com.
Visit this group at https://groups.google.com/group/redis-db.
For more options, visit https://groups.google.com/d/optout.
--

Itamar Haber | Chief OSS Education Officer
Redis Labs ~/redis

Mobile: +972 (54) 567 9692
Twitter: @itamarhaber
Skype: itamar.haber

--
You received this message because you are subscribed to the Google Groups "Redis DB" group.
To unsubscribe from this group and stop receiving emails from it, send an email to redis-db+u...@googlegroups.com.

To post to this group, send email to redi...@googlegroups.com.
Visit this group at https://groups.google.com/group/redis-db.
For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "Redis DB" group.
To unsubscribe from this group and stop receiving emails from it, send an email to redis-db+u...@googlegroups.com.

To post to this group, send email to redi...@googlegroups.com.
Visit this group at https://groups.google.com/group/redis-db.
For more options, visit https://groups.google.com/d/optout.



--

Itamar Haber | Chief OSS Education Officer
Redis Labs ~/redis

Mobile: +972 (54) 567 9692
Twitter: @itamarhaber
Skype: itamar.haber

--
You received this message because you are subscribed to the Google Groups "Redis DB" group.
To unsubscribe from this group and stop receiving emails from it, send an email to redis-db+u...@googlegroups.com.

Dinesh Kumar

unread,
Oct 4, 2017, 12:57:10 AM10/4/17
to redi...@googlegroups.com
Hello Itamar,

What according to you needs to be done to append existing redis IANA documents to cover sentinels and other formats ?

Regards,
Dinesh

To unsubscribe from this group and stop receiving emails from it, send an email to redis-db+unsubscribe@googlegroups.com.

Itamar Haber

unread,
Oct 4, 2017, 4:49:04 AM10/4/17
to Redis DB
Howdy Dinesh,

I really don't know, sorry, but I'm positive that the IANA website has a form for that. At most you can try contacting the IANA staff - from my past dealings with them, they proved to be extremely friendly and helpful. 

Cheers, 
Itamar 

Dinesh Kumar

unread,
Oct 4, 2017, 5:07:54 AM10/4/17
to redi...@googlegroups.com
Hi Itamar,

Thanks for the pointer towards IANA staff. At this point of time, my question is more towards reaching a consensus within the redis community and redis-clients community. How do we agree upon the formats/schemes  before we go ahead and contact IANA team for standardization ?

Regards,
Dinesh

Itamar Haber

unread,
Oct 4, 2017, 3:27:50 PM10/4/17
to Redis DB
Yo Dinesh.

AFAIK we have no "formal" way to agree :) This mailing list is one place to discuss stuff, as well as IRC and perhaps the subreddit. Other than using these to lure client authors like Mark into the discussion, you could approach the other authors individually via their respective repositories.

Personally, I'd like to see this somehow standardized and have all clients adopt a shared scheme (even and perhaps foremost, redis-cli [https://github.com/antirez/redis/pull/3409]).

Lastly, and naturally, for any standardization to take effect we'll need to have Salvatore on board as well :)

Cheers,
Reply all
Reply to author
Forward
0 new messages