From: Ian Jackson Date: Tue, 11 Nov 2014 18:28:07 +0000 (+0000) Subject: ts-hosts-allocate-Executive: Move $variation_age setting X-Git-Url: http://xenbits.xensource.com/gitweb?a=commitdiff_plain;h=9abef8924f0c84066dbe8493299a4de437c48770;p=people%2Fdariof%2Fosstest.git ts-hosts-allocate-Executive: Move $variation_age setting We are going to want to put more stuff in here which depends on $duration_rightaway_adjust. No functional change in this commit. Signed-off-by: Ian Jackson Acked-by: Ian Campbell --- diff --git a/ts-hosts-allocate-Executive b/ts-hosts-allocate-Executive index 73c1a45..67b8891 100755 --- a/ts-hosts-allocate-Executive +++ b/ts-hosts-allocate-Executive @@ -478,12 +478,6 @@ sub hid_recurse ($$) { print DEBUG "$dbg EVAL DURATION $duration va=$variation_age\n"; - if ($jobinfo->{recipe} =~ m/build/) { - $variation_age= 0; - } elsif ($variation_age > 5*86400) { - $variation_age= 5*86400; - } - my @requestlist; foreach my $hid (@hids) { my $req= { @@ -502,6 +496,12 @@ sub hid_recurse ($$) { $duration_rightaway_adjust=0 if $start_time; + if ($jobinfo->{recipe} =~ m/build/) { + $variation_age= 0; + } elsif ($variation_age > 5*86400) { + $variation_age= 5*86400; + } + my $cost= $start_time + $duration + $duration_rightaway_adjust