Commit 1e28149f authored by Leigh B. Stoller's avatar Leigh B. Stoller

Minor fixes. Also, send email if the script exits.

parent f9e18844
......@@ -162,9 +162,9 @@ sub ExpireSlices()
}
my $experiment = $slice->GetExperiment();
if (!defined($experiment)) {
print STDERR "Could not get experiment for $slice.\n";
print STDERR "Could not get experiment for $slice. Expiring ...\n";
$slice->UnLock();
goto skip;
goto cleanup;
}
if ($experiment->Refresh() != 0) {
print STDERR "Could not flush $experiment\n";
......@@ -194,6 +194,7 @@ sub ExpireSlices()
}
}
print STDERR "$slice is idle; releasing.\n";
cleanup:
if (GeniCM::CleanupDeadSlice($slice) != 0) {
print STDERR "Could not release $slice\n";
SENDMAIL($TBOPS, "Could not release slice $slice",
......@@ -271,6 +272,14 @@ sub fatal($)
{
my ($msg) = @_;
#
# Send a message to the testbed list.
#
SENDMAIL($TBOPS,
"ProtoGENI expire daemon died",
$msg,
$TBOPS);
die("*** $0:\n".
" $msg\n");
}
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment