|
|
@ -235,16 +235,13 @@ public class CommandBatchService extends CommandAsyncService {
|
|
|
|
List<Object> responses = new ArrayList<Object>(entries.size());
|
|
|
|
List<Object> responses = new ArrayList<Object>(entries.size());
|
|
|
|
int syncedSlaves = 0;
|
|
|
|
int syncedSlaves = 0;
|
|
|
|
for (BatchCommandData<?, ?> commandEntry : entries) {
|
|
|
|
for (BatchCommandData<?, ?> commandEntry : entries) {
|
|
|
|
if (!isWaitCommand(commandEntry)
|
|
|
|
if (isWaitCommand(commandEntry)) {
|
|
|
|
&& !commandEntry.getCommand().getName().equals(RedisCommands.MULTI.getName())
|
|
|
|
syncedSlaves = (Integer) commandEntry.getPromise().getNow();
|
|
|
|
|
|
|
|
} else if (!commandEntry.getCommand().getName().equals(RedisCommands.MULTI.getName())
|
|
|
|
&& !commandEntry.getCommand().getName().equals(RedisCommands.EXEC.getName())) {
|
|
|
|
&& !commandEntry.getCommand().getName().equals(RedisCommands.EXEC.getName())) {
|
|
|
|
Object entryResult = commandEntry.getPromise().getNow();
|
|
|
|
Object entryResult = commandEntry.getPromise().getNow();
|
|
|
|
entryResult = tryHandleReference(entryResult);
|
|
|
|
entryResult = tryHandleReference(entryResult);
|
|
|
|
responses.add(entryResult);
|
|
|
|
responses.add(entryResult);
|
|
|
|
} else {
|
|
|
|
|
|
|
|
if (isWaitCommand(commandEntry)) {
|
|
|
|
|
|
|
|
syncedSlaves = (Integer) commandEntry.getPromise().getNow();
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|