Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cluster connections fails after upgrade to 1.5.17 from 1.5.16 #2826

Open
JimmyBjorklund opened this issue Sep 3, 2024 · 2 comments
Open
Labels

Comments

@JimmyBjorklund
Copy link

Description

After upgrade to 1.5.17 from 1.5.16 the connect function never returns.

host: clustercfg.XXXXXXXmemorydb.eu-north-1.amazonaws.com
port is: 6379

    const options: RedisClusterOptions = {
      rootNodes: [{
        url:"rediss://" + this.config.redis.host + ":" + this.config.redis.port,
      }]
      ,defaults: {
        username: this.config.redis.username,
        password: this.config.redis.password,
        socket: {
          tls: false
        }
      }
    };
    this.redis = createCluster(options);
    console.log("Connecting to Redis Cluster: " + this.config.redis.host + ":" + this.config.redis.port);
    this.redis.on("error", (err) => Logger.error("Redis Cluster Error"));
    await this.redis
      .connect()
      .then(() => {
        console.log("Connected to Redis Cluster: " + this.config.redis.host + ":" + this.config.redis.port);
      })
      .catch((err) => {
        console.log("Error connecting to Redis Cluster: " + this.config.redis.host + ":" + this.config.redis.port);
        exit(1);
      });

Node.js Version

v20.15.0

Redis Server Version

Engine version 7.1

Node Redis Version

No response

Platform

AWS

Logs

No response

@leibale
Copy link
Contributor

leibale commented Sep 19, 2024

I just tried connecting to a cluster locally and it seems like it works.. I'm not sure what the bug is, and without being able to reproduce it we won't be able to fix it..
If you want we can debug this together, ping me on the redis discord (my handle is @leibale) :)

@JimmyBjorklund
Copy link
Author

JimmyBjorklund commented Oct 23, 2024

Created a sample repo that show the issue.

https://github.com/JimmyBjorklund/redis-test

Hanging version prints ( running version 1.6.0 )

> [email protected] pstart
> node ./app/app.js

Connecting to Redis Cluster: clustercfg.connect-memdb.xxxxx.memorydb.eu-north-1.amazonaws.com:6379
Let's kick it!

Working (running version 1.5.16):

[email protected] pstart
node ./app/app.js

Connecting to Redis Cluster: clustercfg.connect-memdb.xxxxx.memorydb.eu-north-1.amazonaws.com:6379
Let's kick it!
Connected to Redis Cluster: clustercfg.connect-memdb.xxxxx.memorydb.eu-north-1.amazonaws.com:6379
Connected to Redis Cluster: clustercfg.connect-memdb.xxxxx.memorydb.eu-north-1.amazonaws.com:6379

Prebuilt images (working is working and latest is broken):
docker pull ghcr.io/jimmybjorklund/redis-test:working
docker pull ghcr.io/jimmybjorklund/redis-test:latest

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants