IGNITE-1069 Added output of node type (server or client) in Visor commandline top command - Fixes #440.
Signed-off-by: Alexey Kuznetsov <[email protected]> Project: http://git-wip-us.apache.org/repos/asf/ignite/repo Commit: http://git-wip-us.apache.org/repos/asf/ignite/commit/59691291 Tree: http://git-wip-us.apache.org/repos/asf/ignite/tree/59691291 Diff: http://git-wip-us.apache.org/repos/asf/ignite/diff/59691291 Branch: refs/heads/sql-store Commit: 59691291b55265e561ee5b707da8d95d2eee79db Parents: 304370c Author: kcheng <[email protected]> Authored: Mon Feb 1 10:48:49 2016 +0700 Committer: Alexey Kuznetsov <[email protected]> Committed: Mon Feb 1 10:48:49 2016 +0700 ---------------------------------------------------------------------- .../apache/ignite/visor/commands/top/VisorTopologyCommand.scala | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/ignite/blob/59691291/modules/visor-console/src/main/scala/org/apache/ignite/visor/commands/top/VisorTopologyCommand.scala ---------------------------------------------------------------------- diff --git a/modules/visor-console/src/main/scala/org/apache/ignite/visor/commands/top/VisorTopologyCommand.scala b/modules/visor-console/src/main/scala/org/apache/ignite/visor/commands/top/VisorTopologyCommand.scala index 5e278ed..d2ec662 100644 --- a/modules/visor-console/src/main/scala/org/apache/ignite/visor/commands/top/VisorTopologyCommand.scala +++ b/modules/visor-console/src/main/scala/org/apache/ignite/visor/commands/top/VisorTopologyCommand.scala @@ -263,12 +263,13 @@ class VisorTopologyCommand extends VisorConsoleCommand { val hostsT = VisorTextTable() - hostsT #= ("Int./Ext. IPs", "Node ID8(@)", "OS", "CPUs", "MACs", "CPU Load") + hostsT #= ("Int./Ext. IPs", "Node ID8(@)","Node Type", "OS", "CPUs", "MACs", "CPU Load") neighborhood.foreach { case (_, neighbors) => var ips = Set.empty[String] var id8s = List.empty[String] + var nodeTypes = List.empty[String] var macs = Set.empty[String] var cpuLoadSum = 0.0 @@ -287,6 +288,7 @@ class VisorTopologyCommand extends VisorConsoleCommand { neighbors.foreach(n => { id8s = id8s :+ (i.toString + ": " + nodeId8(n.id)) + nodeTypes = nodeTypes :+ (if (n.isClient) "Client" else "Server") i += 1 ips = ips ++ n.addresses() @@ -300,6 +302,7 @@ class VisorTopologyCommand extends VisorConsoleCommand { hostsT += ( ips.toSeq, id8s, + nodeTypes, os, cpus, macs.toSeq,
