]> git.ipfire.org Git - thirdparty/haproxy.git/commitdiff
MINOR: cli/activity: rename the stolen CPU time fields to mention milliseconds
authorWilly Tarreau <w@1wt.eu>
Thu, 22 Nov 2018 15:13:17 +0000 (16:13 +0100)
committerWilly Tarreau <w@1wt.eu>
Thu, 22 Nov 2018 15:13:17 +0000 (16:13 +0100)
The "cpust_{tot,1s,15s}" fields used to report milliseconds but nothing
in the value's title made this explicit. Let's rename the field to report
"cpust_ms_{tot,1s,15s}" to more easily remind that the unit represents
milliseconds.

src/cli.c

index 9652df583d74840250ff739a05d232f5d7f90466..0ec8dc85e67a174ce4f1b4e163ffe221a832fbe2 100644 (file)
--- a/src/cli.c
+++ b/src/cli.c
@@ -1001,9 +1001,9 @@ static int cli_io_handler_show_activity(struct appctx *appctx)
        chunk_appendf(&trash, "\nstream:");       for (thr = 0; thr < global.nbthread; thr++) chunk_appendf(&trash, " %u", activity[thr].stream);
        chunk_appendf(&trash, "\nempty_rq:");     for (thr = 0; thr < global.nbthread; thr++) chunk_appendf(&trash, " %u", activity[thr].empty_rq);
        chunk_appendf(&trash, "\nlong_rq:");      for (thr = 0; thr < global.nbthread; thr++) chunk_appendf(&trash, " %u", activity[thr].long_rq);
-       chunk_appendf(&trash, "\ncpust_tot:");    for (thr = 0; thr < global.nbthread; thr++) chunk_appendf(&trash, " %u", activity[thr].cpust_total/2);
-       chunk_appendf(&trash, "\ncpust_1s:");     for (thr = 0; thr < global.nbthread; thr++) chunk_appendf(&trash, " %u", read_freq_ctr(&activity[thr].cpust_1s)/2);
-       chunk_appendf(&trash, "\ncpust_15s:");    for (thr = 0; thr < global.nbthread; thr++) chunk_appendf(&trash, " %u", read_freq_ctr_period(&activity[thr].cpust_15s, 15000)/2);
+       chunk_appendf(&trash, "\ncpust_ms_tot:"); for (thr = 0; thr < global.nbthread; thr++) chunk_appendf(&trash, " %u", activity[thr].cpust_total/2);
+       chunk_appendf(&trash, "\ncpust_ms_1s:");  for (thr = 0; thr < global.nbthread; thr++) chunk_appendf(&trash, " %u", read_freq_ctr(&activity[thr].cpust_1s)/2);
+       chunk_appendf(&trash, "\ncpust_ms_15s:"); for (thr = 0; thr < global.nbthread; thr++) chunk_appendf(&trash, " %u", read_freq_ctr_period(&activity[thr].cpust_15s, 15000)/2);
        chunk_appendf(&trash, "\navg_loop_us:");  for (thr = 0; thr < global.nbthread; thr++) chunk_appendf(&trash, " %u", swrate_avg(activity[thr].avg_loop_us, TIME_STATS_SAMPLES));
 
        chunk_appendf(&trash, "\n");