微服务版本,redis设置密码无法连接

Blade 未结 2 180
six_six_2005
six_six_2005 2025-03-18 14:26

一、该问题的重现步骤是什么?

1. baldex框架微服务版本redis设置密码,balde_auth无法连接

2. image.png

3.

74cd9ed86255b0337b8674a207b5d8b1.png

ee61aff38723a7d6791b4fe017225649.png

NOAUTH HELLO must be called with the client already authenticated, otherwise the HELLO AUTH option can be used to authenticate the client and select the RESP protocol version at the same time

二、你期待的结果是什么?实际看到的又是什么?


三、你正在使用的是什么产品,什么版本?在什么操作系统上?

4.4,欧拉操作系统


四、请提供详细的错误堆栈信息,这很重要。


五、若有更多详细信息,请在下面提供。

2条回答
  •  six_six_2005
    2025-03-18 17:58

    好的,就是新建普通的测试一下redis的连通性就可以是吧

    作者追问:2025-03-18 17:58

    是的,这么做是先排除掉bladex本身的环境可能

    回答: 2025-03-18 17:58

    我自己新建的工程可以连接redis,你们微服务的nacos的yml配置文件设置密码就不行,不设置可以,下面是redis配置,password设置了密码就报错

    #spring配置

    spring:

    redis:

    ##redis 单机环境配置

    host10.120.137.16

    port6379

    password:

    database0

    sslfalse

    ##redis 集群环境配置

    #cluster:

    #  nodes: 127.0.0.1:7001,127.0.0.1:7002,127.0.0.1:7003

    #  commandTimeout: 5000

    datasource:

    driver-class-namecom.mysql.cj.jdbc.Driver

    #driver-class-name: org.postgresql.Driver

    #driver-class-name: oracle.jdbc.OracleDriver

    #driver-class-name: com.microsoft.sqlserver.jdbc.SQLServerDriver

    druid:

    validation-queryselect 1

    #validation-query: select 1 from dual


    blade:

    lock:

    enabledtrue

    addressredis://10.120.137.16:6379

    password:



代码语言
提交回复