redis.clients.jedis.exceptions.JedisDataException :READONLY You can't write

时间:2022-09-19 17:29:38

分布式直连同步调用测试时出现的错误:主从复制架构下,默认Slave是只读的,如果写入则会报错:

redis.clients.jedis.exceptions.JedisDataException: READONLY You can't write

解决方案:

redis修改redis.windows.conf文件中的    appendonly no