How to set expiration when using Redis geoadd

I am using the new geospatial features in Redis. I know that behind the scenes this uses ZSET.

I add new entries this way:

GEOADD" "report-geo-set" "4.78335244" "32.07223969" "jossef"

How can I add expiration to specific entries (in my case: "jossef")

on my set?

If the API does not provide, is there a way to do this?

Thanks ray.

+4
source share
1 answer

Unfortunately, no - Redis runs out of integer keys, not values, in its corresponding data structures. Geo Hashes implemented on top Sorted sets and expiration of individual members is not supported.

, , . , , , ZRANGEBYSCORE "" ZREM, Geo Hash.

+3

Source: https://habr.com/ru/post/1612113/


All Articles