Fixed - read mode = SLAVE isn't applied for RSet.random() methods. #5871

pull/5884/head
Nikita Koksharov 9 months ago
parent ef90ee11ec
commit 0792155837

@ -245,7 +245,7 @@ public class RedissonSet<V> extends RedissonExpirable implements RSet<V>, ScanIt
@Override
public RFuture<V> randomAsync() {
return commandExecutor.writeAsync(getRawName(), codec, RedisCommands.SRANDMEMBER_SINGLE, getRawName());
return commandExecutor.readAsync(getRawName(), codec, RedisCommands.SRANDMEMBER_SINGLE, getRawName());
}
@Override
@ -255,7 +255,7 @@ public class RedissonSet<V> extends RedissonExpirable implements RSet<V>, ScanIt
@Override
public RFuture<Set<V>> randomAsync(int count) {
return commandExecutor.writeAsync(getRawName(), codec, RedisCommands.SRANDMEMBER, getRawName(), count);
return commandExecutor.readAsync(getRawName(), codec, RedisCommands.SRANDMEMBER, getRawName(), count);
}
@Override

@ -387,7 +387,7 @@ public class RedissonSetMultimapValues<V> extends RedissonExpirable implements R
@Override
public RFuture<V> randomAsync() {
return commandExecutor.writeAsync(getRawName(), codec, RedisCommands.SRANDMEMBER_SINGLE, getRawName());
return commandExecutor.readAsync(getRawName(), codec, RedisCommands.SRANDMEMBER_SINGLE, getRawName());
}
@Override
@ -397,7 +397,7 @@ public class RedissonSetMultimapValues<V> extends RedissonExpirable implements R
@Override
public RFuture<Set<V>> randomAsync(int count) {
return commandExecutor.writeAsync(getRawName(), codec, RedisCommands.SRANDMEMBER, getRawName(), count);
return commandExecutor.readAsync(getRawName(), codec, RedisCommands.SRANDMEMBER, getRawName(), count);
}
@Override

Loading…
Cancel
Save