|
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [Xen-devel] [OSSTEST PATCH 12/26] selecthost: Minor cleanups
Document the syntax for $ident.
Log the ident as well as the selected hostname.
Signed-off-by: Ian Jackson <Ian.Jackson@xxxxxxxxxxxxx>
---
v14: New patch
---
Osstest/TestSupport.pm | 16 +++++++++++++++-
1 file changed, 15 insertions(+), 1 deletion(-)
diff --git a/Osstest/TestSupport.pm b/Osstest/TestSupport.pm
index 168aa9c..8f0122c 100644
--- a/Osstest/TestSupport.pm
+++ b/Osstest/TestSupport.pm
@@ -804,6 +804,20 @@ sub power_state ($$) {
sub selecthost ($) {
my ($ident) = @_;
# must be run outside transaction
+
+ # $ident is <identspec>
+ #
+ # <identspec> can be <ident>, typically "host" or "xxx_host"
+ # which means look up the runvar $r{$ident} which
+ # contains <hostspec>
+ # OR
+ # <identspec> can be <ident>=<hostspec>
+ # which means ignore <ident> except for logging purposes etc.
+ # and use <hostspec>
+ #
+ # <hostspec> uis <hostname> which means use that host (and all
+ # its flags and properties from the configuration and database)
+
my $name;
if ($ident =~ m/=/) {
$ident= $`;
@@ -911,7 +925,7 @@ sub selecthost ($) {
$mjobdb->host_check_allocated($ho);
- logm("host: selected $ho->{Name} ".
+ logm("host $ho->{Ident}: selected $ho->{Name} ".
(defined $ho->{Ether} ? $ho->{Ether} : '<unknown-ether>').
" $ho->{Ip}".
(!$ho->{Shared} ? '' :
--
1.7.10.4
_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxx
http://lists.xen.org/xen-devel
|
![]() |
Lists.xenproject.org is hosted with RackSpace, monitoring our |