Skip to content

Commit

Permalink
Add interface inheritance to inherit & extend javadocs.
Browse files Browse the repository at this point in the history
Signed-off-by: Yury-Fridlyand <[email protected]>
  • Loading branch information
Yury-Fridlyand committed Feb 20, 2024
1 parent 29cdfa4 commit 08a22eb
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 5 deletions.
6 changes: 2 additions & 4 deletions java/client/src/main/java/glide/api/RedisClusterClient.java
Original file line number Diff line number Diff line change
Expand Up @@ -121,26 +121,24 @@ public CompletableFuture<ClusterValue<String>> info(
Info, options.toArgs(), route, response -> ClusterValue.of(handleObjectResponse(response)));
}

/** {@inheritDoc} The command will be routed automatically to all nodes. */
@Override
public CompletableFuture<String> configRewrite() {
return super.configRewrite();
}

/** {@inheritDoc} The command will be routed automatically to all nodes. */
@Override
public CompletableFuture<String> configResetStat() {
return super.configResetStat();
}

@Override
public CompletableFuture<String> configRewrite(Route route) {
public CompletableFuture<String> configRewrite(@NonNull Route route) {
return commandManager.submitNewCommand(
ConfigRewrite, new String[0], route, this::handleStringResponse);
}

@Override
public CompletableFuture<String> configResetStat(Route route) {
public CompletableFuture<String> configResetStat(@NonNull Route route) {
return commandManager.submitNewCommand(
ConfigResetStat, new String[0], route, this::handleStringResponse);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
*
* @see <a href="https://redis.io/commands/?group=server">Server Management Commands</a>
*/
public interface ServerManagementClusterCommands {
public interface ServerManagementClusterCommands extends ServerManagementBaseCommands {

/**
* Get information and statistics about the Redis server. DEFAULT option is assumed. The command
Expand Down Expand Up @@ -71,6 +71,12 @@ public interface ServerManagementClusterCommands {
*/
CompletableFuture<ClusterValue<String>> info(InfoOptions options, Route route);

/** {@inheritDoc} The command will be routed automatically to all nodes. */
CompletableFuture<String> configRewrite();

/** {@inheritDoc} The command will be routed automatically to all nodes. */
CompletableFuture<String> configResetStat();

/**
* Rewrite the configuration file with the current configuration.
*
Expand Down

0 comments on commit 08a22eb

Please sign in to comment.