[6.0] f9f95617c Some varnishtop -f coverage
Dridi Boukelmoune
dridi.boukelmoune at gmail.com
Thu Aug 16 08:53:02 UTC 2018
commit f9f95617c01b158da649945c6d484fee2437482c
Author: Dridi Boukelmoune <dridi.boukelmoune at gmail.com>
Date: Tue May 22 14:02:10 2018 +0200
Some varnishtop -f coverage
diff --git a/bin/varnishtest/tests/u00004.vtc b/bin/varnishtest/tests/u00004.vtc
index 28d58ebdc..71ca1f601 100644
--- a/bin/varnishtest/tests/u00004.vtc
+++ b/bin/varnishtest/tests/u00004.vtc
@@ -15,6 +15,16 @@ client c1 {
shell -expect "fetch" "varnishtop -n ${v1_name} -1"
shell -expect "fetch" "varnishtop -n ${v1_name} -d"
+# without -f
+shell -match "1\\.00 RespHeader Date: [^\\n]+\\n" {
+ varnishtop -n ${v1_name} -1 -i RespHeader
+}
+
+# with -f
+shell -match "1\\.00 RespHeader Date\\n" {
+ varnishtop -n ${v1_name} -1 -f -i RespHeader
+}
+
shell -match "Usage: .*varnishtop <options>" \
"varnishtop -h"
shell -expect "Copyright (c) 2006 Verdens Gang AS" \
diff --git a/bin/varnishtop/varnishtop_options.h b/bin/varnishtop/varnishtop_options.h
index dcad73702..ebf8912c1 100644
--- a/bin/varnishtop/varnishtop_options.h
+++ b/bin/varnishtop/varnishtop_options.h
@@ -40,7 +40,9 @@
#define TOP_OPT_f \
VOPT("f", "[-f]", "First field only", \
"Sort and group only on the first field of each log entry." \
- " This is useful when displaying e.g. stataddr entries," \
+ " For log entries in the form ``prefix: value`` it is the" \
+ " prefix without the colon that is sorted and grouped." \
+ " This is useful when displaying e.g. ReqStart entries," \
" where the first field is the client IP address." \
)
More information about the varnish-commit
mailing list