You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@ignite.apache.org by nt...@apache.org on 2016/02/01 15:21:46 UTC

[38/49] ignite git commit: IGNITE-1069 Added output of node type (server or client) in Visor commandline top command.

IGNITE-1069 Added output of node type (server or client) in Visor commandline top command.


Project: http://git-wip-us.apache.org/repos/asf/ignite/repo
Commit: http://git-wip-us.apache.org/repos/asf/ignite/commit/e5fda53a
Tree: http://git-wip-us.apache.org/repos/asf/ignite/tree/e5fda53a
Diff: http://git-wip-us.apache.org/repos/asf/ignite/diff/e5fda53a

Branch: refs/heads/ignite-2435
Commit: e5fda53ae5f0e64e63f97db9d664081d24b34fa7
Parents: c92c274
Author: Alexey Kuznetsov <ak...@apache.org>
Authored: Mon Feb 1 10:08:21 2016 +0700
Committer: Alexey Kuznetsov <ak...@apache.org>
Committed: Mon Feb 1 10:08:21 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/e5fda53a/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,