shotover / shotover-proxy

L7 data-layer proxy
https://docs.shotover.io
Apache License 2.0
86 stars 17 forks source link

RedisSinkCluster does not know of a node containing the required slot #740

Open weixiong-ins opened 2 years ago

weixiong-ins commented 2 years ago

Describe the bug

When connected to shotover from a Redis cluster, got the following error

➜   redis-cli -c -h 34.230.93.245 -p 6378
34.230.93.245:6378> set name asdf
(error) ERR Shotover RedisSinkCluster does not know of a node containing the required slot

To Reproduce

The bug might be annoying to reproduce. Shotover crashes as expected if the Redis cluster is completely unformed (“protocol error: empty slot map!“). The problem is when Shotover starts while the cluster is being formed, when some slots have been assigned but not all.

Configuration

config.yaml

main_log_level: "info,shotover_proxy=info"
observability_interface: "127.0.0.1:9001"

Topology

topology.yaml

sources:
  redis_prod:
    Redis: {batch_size_hint: 1000, listen_addr: '0.0.0.0:6378', connection_limit: 3000000}
chain_config:
  redis_chain:
  - RedisClusterPortsRewrite: {new_port: 6378}
  - RedisSinkCluster:
      first_contact_points: ['34.230.93.245:6379']
source_to_chain_mapping: {redis_prod: redis_chain}

Expected behaviour

The error path that returns the “does not know of a node containing the required slot” message needs to trigger the re-fetching of the slot map.

Systems and Version:

conorbros commented 7 months ago

Closing as this bug has not reported in the last while.

rukai commented 7 months ago

I don't believe we have addressed this yet. Unless there was some PR I forgot about?