1
0
Fork 0
mirror of https://git.rwth-aachen.de/acs/public/villas/node/ synced 2025-03-09 00:00:00 +01:00

fixed for rate

This commit is contained in:
Steffen Vogel 2016-10-20 21:16:47 -04:00
parent 982cd91d63
commit d4e6204e8e
2 changed files with 6 additions and 8 deletions

View file

@ -18,13 +18,12 @@ void hook_stats_header()
{
#define UNIT(u) "(" YEL(u) ")"
stats("%-40s|%19s|%19s|%19s|%19s|%19s|%10s|", "Source " MAG("=>") " Destination",
stats("%-40s|%19s|%19s|%19s|%19s|%19s|", "Source " MAG("=>") " Destination",
"OWD" UNIT("S") " ",
"Rate" UNIT("p/S") " ",
"Drop" UNIT("p") " ",
"Skip" UNIT("p") " ",
"Inval" UNIT("p") " ",
"Overuns "
"Inval" UNIT("p") " "
);
line();
}
@ -83,8 +82,8 @@ int hook_stats(struct path *p, struct hook *h, int when, struct sample *smps[],
break;
case HOOK_PERIODIC:
stats("%-40.40s|%10s|%10s|%10ju|%10ju|%10ju|%10ju|", path_name(p), "", "",
p->dropped, p->skipped, p->invalid, p->overrun);
stats("%-40.40s|%10s|%10s|%10ju|%10ju|%10ju|", path_name(p), "", "",
p->dropped, p->skipped, p->invalid);
break;
}
@ -124,7 +123,6 @@ int hook_stats_send(struct path *p, struct hook *h, int when, struct sample *smp
smp->data[i++].f = p->invalid;
smp->data[i++].f = p->skipped;
smp->data[i++].f = p->dropped;
smp->data[i++].f = p->overrun;
smp->data[i++].f = p->hist.owd.last,
smp->data[i++].f = 1.0 / p->hist.gap_msg.last;
smp->data[i++].f = 1.0 / p->hist.gap_recv.last;

View file

@ -112,8 +112,8 @@ int path_stop(struct path *p)
{
info("Stopping path: %s", path_name(p));
pthread_cancel(p->recv_tid);
pthread_join(p->recv_tid, NULL);
pthread_cancel(p->tid);
pthread_join(p->tid, NULL);
if (hook_run(p, NULL, 0, HOOK_PATH_STOP))
return -1;