$set_info->('priority', $priority);
$set_info->('sub-priority',$ENV{OSSTEST_RESOURCE_SUBPRIORITY});
$set_info->('preinfo', $ENV{OSSTEST_RESOURCE_PREINFO});
+ $set_info->('feature-noalloc', 1);
if (defined $waitstart) {
$set_info->('wait-start',$waitstart);
logm("resource allocation: awaiting our slot...");
- $_= <$qserv>; defined && m/^\!OK think\s$/ or die "$_ ?";
+ $_= <$qserv>;
+ defined && m/^\!OK think( noalloc)?\s$/ or die "$_ ?";
+ my $noalloc = $1 // '';
opendb_tests();
read($qserv, $jplan, $jplanlen) == $jplanlen or die $!;
my $jplanprint= $jplan;
chomp $jplanprint;
- logm("resource allocation: obtained base plan.");
+ logm("resource allocation: obtained base plan$noalloc.");
$debugm->("base plan = ", $jplanprint);
$plan= from_json($jplan);
}, sub {
if (!eval {
- ($ok, $bookinglist) = $resourcecall->($plan, 1);
+ ($ok, $bookinglist) = $resourcecall->($plan, !$noalloc);
1;
}) {
warn "resourcecall $@";
> set-info sub-priority ... } queue adjustment
> set-info wait-start-adjust ... }
+ > set-info feature-noalloc 1
+ The client understands `!OK think noalloc'.
+
> wait
I want to join the plan
- < !OK think
+ < !OK think [noalloc]
Now is the time to add yourself to the plan
+ `noalloc' means client must not not actually allocate.
> get-plan
< OK get-plan BYTES