Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Server status command #21

Merged
merged 2 commits into from
Jan 19, 2016
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion client/core/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
<parent>
<groupId>com.8kdata.mongowp.client</groupId>
<artifactId>parent-pom</artifactId>
<version>0.40-SNAPSHOT</version>
<version>0.41-SNAPSHOT</version>
</parent>

<artifactId>core</artifactId>
Expand Down
2 changes: 1 addition & 1 deletion client/driver-wrapper/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
<parent>
<groupId>com.8kdata.mongowp.client</groupId>
<artifactId>parent-pom</artifactId>
<version>0.40-SNAPSHOT</version>
<version>0.41-SNAPSHOT</version>
</parent>

<artifactId>driver-wrapper</artifactId>
Expand Down
2 changes: 1 addition & 1 deletion client/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
<parent>
<groupId>com.8kdata.mongowp</groupId>
<artifactId>mongowp-parent</artifactId>
<version>0.40-SNAPSHOT</version>
<version>0.41-SNAPSHOT</version>
</parent>

<groupId>com.8kdata.mongowp.client</groupId>
Expand Down
2 changes: 1 addition & 1 deletion library/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
<parent>
<groupId>com.8kdata.mongowp</groupId>
<artifactId>mongowp-parent</artifactId>
<version>0.40-SNAPSHOT</version>
<version>0.41-SNAPSHOT</version>
</parent>

<groupId>com.8kdata.mongowp.api.safe.library</groupId>
Expand Down
2 changes: 1 addition & 1 deletion library/v3m0/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
<parent>
<groupId>com.8kdata.mongowp.api.safe.library</groupId>
<artifactId>library</artifactId>
<version>0.40-SNAPSHOT</version>
<version>0.41-SNAPSHOT</version>
</parent>

<artifactId>v3m0</artifactId>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,8 @@
import com.eightkdata.mongowp.mongoserver.api.safe.library.v3m0.commands.diagnostic.CollStatsCommand.CollStatsArgument;
import com.eightkdata.mongowp.mongoserver.api.safe.library.v3m0.commands.diagnostic.CollStatsCommand.CollStatsReply;
import com.eightkdata.mongowp.mongoserver.api.safe.library.v3m0.commands.diagnostic.ListDatabasesCommand.ListDatabasesReply;
import com.eightkdata.mongowp.mongoserver.api.safe.library.v3m0.commands.diagnostic.ServerStatusCommand.ServerStatusArgument;
import com.eightkdata.mongowp.mongoserver.api.safe.library.v3m0.commands.diagnostic.ServerStatusCommand.ServerStatusReply;
import com.eightkdata.mongowp.mongoserver.api.safe.tools.Empty;
import com.google.common.collect.ImmutableList;
import com.google.common.collect.ImmutableMap;
Expand All @@ -22,7 +24,8 @@ public class DiagnosticCommands implements Iterable<Command> {
private final ImmutableList<Command> commands = ImmutableList.<Command>of(
CollStatsCommand.INSTANCE,
ListDatabasesCommand.INSTANCE,
BuildInfoCommand.INSTANCE
BuildInfoCommand.INSTANCE,
ServerStatusCommand.INSTANCE
);

@Override
Expand All @@ -38,11 +41,14 @@ public static abstract class DiagnosticCommandsImplementationsBuilder implements

public abstract CommandImplementation<Empty, BuildInfoResult> getBuildInfoImplementation();

public abstract CommandImplementation<ServerStatusArgument, ServerStatusReply> getServerStatusImplementation();

private Map<Command, CommandImplementation> createMap() {
return ImmutableMap.<Command, CommandImplementation>builder()
.put(CollStatsCommand.INSTANCE, getCollStatsImplementation())
.put(ListDatabasesCommand.INSTANCE, getListDatabasesImplementation())
.put(BuildInfoCommand.INSTANCE, getBuildInfoImplementation())
.put(ServerStatusCommand.INSTANCE, getServerStatusImplementation())
.build();
}

Expand Down
Loading