From mboxrd@z Thu Jan 1 00:00:00 1970 From: Ian Campbell Subject: Re: [OSSTEST PATCH 3/1] ts-hosts-allocate-Executive: Print more info about booking to main log Date: Tue, 29 Sep 2015 17:08:54 +0100 Message-ID: <1443542934.16718.139.camel@citrix.com> References: <1443536078-23449-1-git-send-email-ian.jackson@eu.citrix.com> <1443540459-31266-1-git-send-email-ian.jackson@eu.citrix.com> <1443540459-31266-2-git-send-email-ian.jackson@eu.citrix.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: Received: from mail6.bemta14.messagelabs.com ([193.109.254.103]) by lists.xen.org with esmtp (Exim 4.72) (envelope-from ) id 1ZgxWZ-0002yq-LP for xen-devel@lists.xenproject.org; Tue, 29 Sep 2015 16:13:03 +0000 In-Reply-To: <1443540459-31266-2-git-send-email-ian.jackson@eu.citrix.com> List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xen.org Errors-To: xen-devel-bounces@lists.xen.org To: Ian Jackson , xen-devel@lists.xenproject.org List-Id: xen-devel@lists.xenproject.org On Tue, 2015-09-29 at 16:27 +0100, Ian Jackson wrote: > Signed-off-by: Ian Jackson > --- > Osstest/Executive.pm | 12 +++++++++++- > 1 file changed, 11 insertions(+), 1 deletion(-) > > diff --git a/Osstest/Executive.pm b/Osstest/Executive.pm > index aeb8c25..3475862 100644 > --- a/Osstest/Executive.pm > +++ b/Osstest/Executive.pm > @@ -743,9 +743,19 @@ sub alloc_resources { > }]); > > if ($bookinglist && $ok!=-1) { > + my %prstart; > + foreach my $book (@{ $bookinglist->{Bookings} }) { > + my $pr = $book->{Reso}; > + $pr .= " [$book->{Xinfo}]" if defined $book > ->{Xinfo}; > + push @{ $prstart{ $book->{Start }} }, $pr; ^ stray space? > + } > + my $pr = ''; > + foreach my $start (sort { $a <=> $b } keys %prstart) { > + $pr .= " \@$start @{ $prstart{$start} }"; Even with one reso and its Xinfo this is going to be quite a long line, isn't it? I don't think it really matters in the context, so in any case Acked-by: Ian Campbell > + } > my $jbookings= to_json($bookinglist); > chomp($jbookings); > - logm("resource allocation: booking."); > + logm("resource allocation: booking$pr."); > $debugm->("bookings = ", $jbookings); > > printf $qserv "book-resources %d\n", length $jbookings