aboutsummaryrefslogtreecommitdiffstats
path: root/tools/libxen/test
diff options
context:
space:
mode:
authorEwan Mellor <ewan@xensource.com>2007-03-23 13:27:29 +0000
committerEwan Mellor <ewan@xensource.com>2007-03-23 13:27:29 +0000
commitf38e3b431b2f8562218758044c4486fe8da0e6dd (patch)
tree7a6c782bebc16221fb3d345b06c596eab5cd5e3c /tools/libxen/test
parent6dcfe86140cefa9d91a55a9412f44b87fadb3b39 (diff)
downloadxen-f38e3b431b2f8562218758044c4486fe8da0e6dd.tar.gz
xen-f38e3b431b2f8562218758044c4486fe8da0e6dd.tar.bz2
xen-f38e3b431b2f8562218758044c4486fe8da0e6dd.zip
Add a last_updated field to every metrics class.
Signed-off-by: Ewan Mellor <ewan@xensource.com>
Diffstat (limited to 'tools/libxen/test')
-rw-r--r--tools/libxen/test/test_bindings.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/tools/libxen/test/test_bindings.c b/tools/libxen/test/test_bindings.c
index 1471814d81..c709e64867 100644
--- a/tools/libxen/test/test_bindings.c
+++ b/tools/libxen/test/test_bindings.c
@@ -592,6 +592,11 @@ static void print_vm_metrics(xen_session *session, xen_vm vm)
return;
}
+ char time[256];
+ struct tm *tm = localtime(&vm_metrics_record->last_updated);
+ strftime(time, 256, "Metrics updated at %c, local time.\n", tm);
+ printf(time);
+
for (size_t i = 0; i < vm_metrics_record->vcpus_utilisation->size; i++)
{
printf("%"PRId64" -> %lf.\n",