Object encoding fails with ClusterError: TTL exhausted error
See original GitHub issueFrom 1.1.0 version. From time to time my test script fails with ClusterError: TTL exhausted error with code like this:
key_with_types = []
for key in ret:
obj_encoding = self.redis.object(infotype='ENCODING', key=key)
obj_type = self.redis.type(key)
key_with_types.append({'type': obj_type, 'encoding': obj_encoding})
This happens always with any values of reinitialize_steps. From library source i see that execution tree in client.py
always goes with that case then i got this error:
- Seng
Object encoding
command - Catch
MoveError
- Select
redirect_addr
- Try again
Actually redirect_addr
will never be never used in this while loop. The AskError
will never be catched becouse of asking
variable will never be True in this loop.
The dirty fix (and i do not know is this correct) is set asking=True if refresh_table_asap
happens.
Issue Analytics
- State:
- Created 8 years ago
- Comments:10 (7 by maintainers)
Top Results From Across the Web
Grokzen/redis-py-cluster - Gitter
ClusterError : TTL exhausted. Output completed (1 sec consumed) - Normal Termination Hi,when i use redis-py-cluster got the problem,i google found it's a...
Read more >Grokzen/redis-py-cluster | Build 470 - Coveralls.io
1 # ‑*‑ coding: utf‑8 ‑*‑
3 # python std lib
4 import random 18×
5 import sys 18×
Read more >Redis TTL Exhaustion Error - Reddit
I have a service which currently for tech debt reason I can't fully update so using Redis 3.0+ but have this issue where...
Read more >Aerospike Go Client v6 - Go Packages
MaxUint32 // TTLDontUpdate will not change the record's ttl when record is ... func NewCluster(policy *ClientPolicy, hosts []*Host) (*Cluster, Error).
Read more >101 WXE-00010 to WXE-21271 - Oracle Help Center
WXE-08002: Failed to find an Oracle Web Cache listening port that does not require SSL ... Action: Check the XML object for possible...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
@Grokzen What I ended up doing- which may or not be helpful to you was to just bring up a single node with cluster-enabled yes in its redis.conf and nothing else. Once it was up I ran:
I just needed a node with cluster semantics, to mimic our production stack, I didn’t actually need a multiple node cluster, so this approach seemed to work fine, all other containers in my compose setup can talk to the node in question. I wonder (but did not test it) if it’s possible to set redis.conf to bind to a hostname rather than to an IP, i.e.:
in the redis.conf ^^^^ in hopes that it would make cluster slots return a hostname rather than 127.0.0.1
@pq-dong This is not a issuissue with this lib, the issue is that you are running the redis servers inside docker and when you do that, then redis will track the docker ip address that is inside the container and when your client connects to each server, redis returns to the client that “all nodes are here, here and over here” and if you connect your client from outside the machine that docker runs on, it will not know where your cluster is when it tries to resolve the ip address of the docker container. The difference between systems might be what IP address that the docker container exposes or binds to it’s internal cluster state.