Skip to content

Commit

Permalink
Polishing redis#1340
Browse files Browse the repository at this point in the history
scriptKill on the reactive Cluster API now correctly calls scriptKill instead of scriptFlush. Fix test.

Original pull request: redis#1341
  • Loading branch information
mp911de committed Jul 13, 2020
1 parent 79ea527 commit a273e29
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -364,7 +364,7 @@ public Mono<String> scriptFlush() {

@Override
public Mono<String> scriptKill() {
Map<String, Publisher<String>> publishers = executeOnNodes(RedisScriptingReactiveCommands::scriptFlush, ALL_NODES);
Map<String, Publisher<String>> publishers = executeOnNodes(RedisScriptingReactiveCommands::scriptKill, ALL_NODES);
return Flux.merge(publishers.values()).onErrorReturn("OK").last();
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,8 @@
import io.lettuce.test.settings.TestSettings;

/**
* Integration tests for {@link StatefulRedisClusterConnection}.
*
* @author Mark Paluch
*/
@SuppressWarnings("rawtypes")
Expand Down Expand Up @@ -381,7 +383,7 @@ void scriptFlush() {

@Test
void scriptKill() {
assertThat(sync.scriptKill()).isEqualTo("OK");
assertThatThrownBy(sync::scriptKill).hasMessageContaining("NOTBUSY");
}

@Test
Expand Down

0 comments on commit a273e29

Please sign in to comment.