Skip to content

Redis Cluster support #5

Description

@nantiferov

Hi,

Thank you for this wonderful tool. I was using mentioned in readme redis analysers in ruby and python and this one is way better and much more useful when you need to debug what stored in redis and how much memory keys take.

I tested this tool today against one of the nodes in Redis Cluster and apparently cluster isn't supported. Log:

$ redis-analyzer -u replica_host:6378/0
thread 'main' panicked at src/analyzer.rs:147:18:
memory usage command: An error was signalled by the server: 4617 master_host:6379
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace

So basically I run analyzer against replica_host, but it probably got redirect and went to master_host and then failed.
I can provide backtrace, but I think it should be reproducible on any Redis Cluster.

Versions:

  • redis 7.0.8
  • redis-analyzer 0.3.0

I think easiest solution for this would be to ignore internal redirects and analyze what is located on each node without trying to collect full picture from whole cluster, since it could be time consuming and create too much load.

UPD: v0.3.0 works with master nodes (showing stats for single node keys only), but fails for replicas. v0.4.0 fails on both master and replicas.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions