marsadm: new primitive writeback-rest

This commit is contained in:
Thomas Schoebel-Theuer 2019-04-04 12:53:01 +02:00 committed by Thomas Schoebel-Theuer
parent 867be8a743
commit 14a94155d7

View File

@ -4489,6 +4489,13 @@ sub eval_fn {
my $what = $1;
return eval_fn($env, "$what-lognr", "") - eval_fn($env, "replay-lognr", "");
}
if (/^writeback[-_]?rest$/) {
my $lnk = $$env{"resdir"} . "/replay-" . $$env{"host"};
my $link = get_link($lnk, 1);
$link =~ m/,([0-9]+)$/;
return $1 if defined($1);
return 0;
}
if (/^(replay|work)[-_]?(pos)$/) {
my $what = $1;
my $op = $2;
@ -5400,6 +5407,8 @@ my %trivial_globs =
=> "",
"{sync,fetch,replay,work}-{rest,{almost-,threshold-,}reached,percent,permille,vector}"
=> "",
"writeback-rest"
=> "",
"{sync,fetch,replay}-{rate,remain}"
=> "",
"replay-basenr"