Skip to content

actually dial i/o timeout much bigger than DialTimeOut in ClusterOptions #2641

@IcefireCgrbza

Description

@IcefireCgrbza

Discussed in #2640

Originally posted by IcefireCgrbza July 4, 2023
I want to test my system's downgrading abilit, so I mock redis sigstop error using kill -SIGSTOP. When redis sigstop happen, redis get and set command using go-redis becoming very slow. It cost bigger than 10 second when go-redis return dial i/o timeout error. I dont understand why timeout happen so slow, can anyone explain it?

my system is using redis cluster mode, go-redis version is v8.11.5, cluster client initialization code like below:

opt := &redis.ClusterOptions{
		Addrs:        servers,
		MaxRedirects: 3
		DialTimeout:  250 * time.Millisecond,
		ReadTimeout:  1000 * time.Millisecond,
		WriteTimeout: 1000 * time.Millisecond,
		PoolTimeout:  2000 * time.Millisecond,
		IdleTimeout:  5 * time.Minute,
		MinIdleConns: 3,
		PoolSize:     100,
		MaxRetries:   3,
}

client := redis.NewClusterClient(opt)
```</div>

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