Open mxzhu opened 1 year ago
rt,设置IPv6带端口 哨兵模式 报错 var csRedis1 = new CSRedis.CSRedisClient( connectionString: cacheConfig.Redis.ConnectionString, sentinels:new[] { "[fe80::5423:f83d:e19e:97fd%5]:26379", "[fe80::5423:f83d:e19e:98fd%5]:26379", "[fe80::5423:f83d:e19e:99fd%5]:26379" }); 具体是源码里面这里 public RedisSentinelManager(bool readOnly, params string[] sentinels) { _readOnly = readOnly; _sentinels = new LinkedList<Tuple<string, int>>(); foreach (string text in sentinels) { string[] array = text.Split(new char[1] { ':' }); string host = array[0].Trim(); //报错 System.FormatException:“Input string was not in a correct format." int port = int.Parse(array[1]); Add(host, port); } }
建议切换到 FreeRedis,发布已经3年
rt,设置IPv6带端口 哨兵模式 报错 var csRedis1 = new CSRedis.CSRedisClient( connectionString: cacheConfig.Redis.ConnectionString, sentinels:new[] { "[fe80::5423:f83d:e19e:97fd%5]:26379", "[fe80::5423:f83d:e19e:98fd%5]:26379", "[fe80::5423:f83d:e19e:99fd%5]:26379" }); 具体是源码里面这里 public RedisSentinelManager(bool readOnly, params string[] sentinels) { _readOnly = readOnly; _sentinels = new LinkedList<Tuple<string, int>>(); foreach (string text in sentinels) { string[] array = text.Split(new char[1] { ':' }); string host = array[0].Trim(); //报错 System.FormatException:“Input string was not in a correct format." int port = int.Parse(array[1]); Add(host, port); } }