From c51d53f02053c219497f05a2f68ebd83c43b72b1 Mon Sep 17 00:00:00 2001
From: Tomas Plesnik <plesnik@ics.muni.cz>
Date: Thu, 19 Mar 2015 13:33:20 +0100
Subject: [PATCH] uprava tabulky klientu podle getClients.pl
---
src/warden-client/bin/info.pl | 28 ++++++++++++++--------------
1 file changed, 14 insertions(+), 14 deletions(-)
diff --git a/src/warden-client/bin/info.pl b/src/warden-client/bin/info.pl
index c466f2e..3719ecd 100755
--- a/src/warden-client/bin/info.pl
+++ b/src/warden-client/bin/info.pl
@@ -28,23 +28,23 @@ use WardenClient;
# obtain information about already registered clients
my @clients = WardenClient::getClientInfo() or exit 1; # receive data or exit
-print "+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+\n";
-print "| Client ID | Hostname | Registered | Requestor | Service | CT | Type | ROE | Description tags | IP Net Client |\n";
-print "+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+\n";
+print "+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+\n";
+print "| Client ID | Hostname | Registered | Requestor | Service | CT | Type | ROE | Description tags | IP Net Client |\n";
+print "+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+\n";
foreach (@clients) {
- printf("| %-10s ", $_->{'client_id'} || "NULL");
- printf("| %-30s ", $_->{'hostname'} || "NULL");
- printf("| %19s ", $_->{'registered'} || "NULL");
- printf("| %-23s ", $_->{'requestor'} || "NULL");
- printf("| %-25s ", $_->{'service'} || "NULL");
- printf("| %-2s ", $_->{'client_type'} || "NULL");
- printf("| %-15s ", $_->{'type'} || "NULL");
- printf("| %-4s ", $_->{'receive_own_events'} || "NULL");
- printf("| %-50s ", $_->{'description_tags'} || "NULL");
- printf("| %-18s |\n", $_->{'ip_net_client'} || "NULL");
+ printf("| %-14s ", $_->{'client_id'} || "unknown");
+ printf("| %-36s ", $_->{'hostname'} || "unknown");
+ printf("| %19s ", $_->{'registered'} || "unknown");
+ printf("| %-27s ", $_->{'requestor'} || "unknown");
+ printf("| %-22s ", $_->{'service'} || "-");
+ printf("| %-1s ", $_->{'client_type'} || "unknown");
+ printf("| %-16s ", $_->{'type'} || "-");
+ printf("| %-1s ", $_->{'receive_own_events'} || "-");
+ printf("| %-47s ", $_->{'description_tags'} || "-");
+ printf("| %-18s |\n", $_->{'ip_net_client'} || "unknown");
}
-print "+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+\n";
+print "+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+\n";
print "\n";
print "Current registered clients in: " . scalar localtime(time) . "\n";
--
GitLab