Open WisdomPill opened 2 years ago
@WisdomPill is this one resolved or are we still looking for help here? I'm interested if its needed
still looking for an implementation, #654 is a very good attempt at it on the sets side, if you want to propose a solution you're very welcome to do so 😄
is available to work on this issue?
Hello @LucianaAG I think @kysre is doing all right here, you can try to do something similar to his PR for sets maybe?
support for hset
, hlen
, hdel
, hkeys
and hexists
has been added thanks to the efforts of @kysre.
Things left to add to make it complete are.
ShardClient
(this should be fairly easy, replacing get_client
with method with make_key and get_server based on the key should do the trick like it is done in other ShardedClient
methods)HDEL
HEXISTS
HGET
quite importantHGETALL
quite importantHINCRBY
HINCRYBYFLOAT
HKEYS
HLEN
HMGET
HMSET
HRANDFIELD
not relevantHSCAN
HSET
HSETNX
relevant could be implemented in .hset()
HSTRLEN
not relevantHVALS
not relevantany contribution is welcome, I consider this a beginner friendly issue
Hi, @WisdomPill I extended support for the missing hashmap functions and would appreciate your feedback when you have some spare time.
HINCRYBYFLOAT
is one of the functions that is missing and I think it would require a bit more work to implement given how we do the decoding/encoding of the values https://github.com/jazzband/django-redis/blob/master/django_redis/client/default.py#L509-L518 I worry if we explicitly store the float value it would come up as incompatible change. Let me know what are your thoughts on this and thanks again.
Problem Statement
django-redis
should introduce hasmaps and support basic operations,hset
,hdel
,hlen
,hkeys
andhexists
.Describe the solution you'd like Add an interface similar to
redis-py
to support hasps