使用docker部署的redis集群 ,项目连接后,缓存几次数据后,就会出现org.springframework.data.redis.TooManyClusterRedirectionsException: No more cluster attempts left.; nested exception is redis.clients.jedis.exceptions.JedisClusterMaxAttemptsException: No more cluster attempts left.这个异常 ,大概每3-4次左右,docker上的集群测试没有问题
我发现 因为之前使用阿里云服务器搭建的redis集群 ,项目因此使用的公网ip 而如果使用本机虚拟机通过docker搭建redis集群 使用内网ip,则不存在这个问题
https://blog.csdn.net/weixin_46017976/article/details/109993478