diff options
author | Harald Musum <musum@yahooinc.com> | 2021-12-06 19:40:17 +0100 |
---|---|---|
committer | Harald Musum <musum@yahooinc.com> | 2021-12-06 19:40:17 +0100 |
commit | c4aa35c9c75a511eb7322ac167d0a962e349e55e (patch) | |
tree | 9b1f2803101f383dd0a15f368f22e02442664489 /config-proxy | |
parent | 091a90a1b5a4db8ade3369c7c416a4e02491bbb9 (diff) |
Remove undocumented RPC command that has never been used
Diffstat (limited to 'config-proxy')
-rw-r--r-- | config-proxy/src/main/java/com/yahoo/vespa/config/proxy/ConfigProxyRpcServer.java | 24 | ||||
-rw-r--r-- | config-proxy/src/test/java/com/yahoo/vespa/config/proxy/ConfigProxyRpcServerTest.java | 16 |
2 files changed, 1 insertions, 39 deletions
diff --git a/config-proxy/src/main/java/com/yahoo/vespa/config/proxy/ConfigProxyRpcServer.java b/config-proxy/src/main/java/com/yahoo/vespa/config/proxy/ConfigProxyRpcServer.java index c7f6530f81c..f2d16399712 100644 --- a/config-proxy/src/main/java/com/yahoo/vespa/config/proxy/ConfigProxyRpcServer.java +++ b/config-proxy/src/main/java/com/yahoo/vespa/config/proxy/ConfigProxyRpcServer.java @@ -79,10 +79,6 @@ public class ConfigProxyRpcServer implements Runnable, TargetWatcher, RpcServer this::ping) .methodDesc("ping") .returnDesc(0, "ret code", "return code, 0 is OK")); - supervisor.addMethod(new Method("printStatistics", "", "s", - this::printStatistics) - .methodDesc("printStatistics") - .returnDesc(0, "statistics", "Statistics for server")); supervisor.addMethod(new Method("listCachedConfig", "", "S", this::listCachedConfig) .methodDesc("list cached configs)") @@ -145,26 +141,6 @@ public class ConfigProxyRpcServer implements Runnable, TargetWatcher, RpcServer }); } - /** - * Returns a String with statistics data for the server. - * - * @param req a Request - */ - private void printStatistics(Request req) { - dispatchRpcRequest(req, () -> { - StringBuilder sb = new StringBuilder(); - sb.append("\nDelayed responses queue size: "); - sb.append(proxyServer.delayedResponses().size()); - sb.append("\nContents: "); - for (DelayedResponse delayed : proxyServer.delayedResponses().responses()) { - sb.append(delayed.getRequest().toString()).append("\n"); - } - - req.returnValues().add(new StringValue(sb.toString())); - req.returnRequest(); - }); - } - private void listCachedConfig(Request req) { dispatchRpcRequest(req, () -> listCachedConfig(req, false)); } diff --git a/config-proxy/src/test/java/com/yahoo/vespa/config/proxy/ConfigProxyRpcServerTest.java b/config-proxy/src/test/java/com/yahoo/vespa/config/proxy/ConfigProxyRpcServerTest.java index 1bcf8d5d8be..fbe7a6c74d9 100644 --- a/config-proxy/src/test/java/com/yahoo/vespa/config/proxy/ConfigProxyRpcServerTest.java +++ b/config-proxy/src/test/java/com/yahoo/vespa/config/proxy/ConfigProxyRpcServerTest.java @@ -133,7 +133,7 @@ public class ConfigProxyRpcServerTest { } /** - * Tests printStatistics RPC command + * Tests listSourceConnections RPC command */ @Test public void testRpcMethodListSourceConnections() throws ListenFailedException { @@ -151,20 +151,6 @@ public class ConfigProxyRpcServerTest { } /** - * Tests printStatistics RPC command - */ - @Test - public void testRpcMethodPrintStatistics() { - Request req = new Request("printStatistics"); - client.invoke(req); - assertFalse(req.errorMessage(), req.isError()); - assertThat(req.returnValues().size(), is(1)); - assertThat(req.returnValues().get(0).asString(), is("\n" + - "Delayed responses queue size: 0\n" + - "Contents: ")); - } - - /** * Tests invalidateCache RPC command */ @Test |