Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
V
varnishevent
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
1
Issues
1
List
Board
Labels
Milestones
Merge Requests
1
Merge Requests
1
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
uplex-varnish
varnishevent
Commits
26c023d9
Commit
26c023d9
authored
Apr 25, 2019
by
Nils Goroll
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
leave trace files from vslarg.sh for analysis
parent
afa9a185
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
24 additions
and
7 deletions
+24
-7
Makefile.am
src/test/Makefile.am
+9
-1
vslarg.sh
src/test/vslarg.sh
+15
-6
No files found.
src/test/Makefile.am
View file @
26c023d9
...
@@ -7,7 +7,15 @@ TESTS = test_data test_strfTIM test_hdrtrie test_format test_writer \
...
@@ -7,7 +7,15 @@ TESTS = test_data test_strfTIM test_hdrtrie test_format test_writer \
ncsa.sh vslarg.sh regress.sh
ncsa.sh vslarg.sh regress.sh
# artifacts of the regression test
# artifacts of the regression test
CLEANFILES
=
test.log output.log
CLEANFILES
=
\
test.log
\
output.log
\
vslarg.sh.trc.dash-C
\
vslarg.sh.trc.no
\
vslarg.sh.trc.query
\
vslarg.sh.trc.raw
\
vslarg.sh.trc.request
\
vslarg.sh.trc.vxid
check_PROGRAMS
=
test_data test_strfTIM test_format test_writer test_hdrtrie
check_PROGRAMS
=
test_data test_strfTIM test_format test_writer test_hdrtrie
...
...
src/test/vslarg.sh
View file @
26c023d9
...
@@ -7,13 +7,17 @@ echo "... testing standard VSL args"
...
@@ -7,13 +7,17 @@ echo "... testing standard VSL args"
IN
=
varnish-4.1.0-doc.log
IN
=
varnish-4.1.0-doc.log
CONF
=
varnishevent.conf
CONF
=
varnishevent.conf
LOG
=
/dev/null
LOG
=
/dev/null
TRC
=
$(
basename
$0
)
.trc
rm
-rf
${
TRC
}
mkdir
${
TRC
}
# Ensure that the local time date formatters produce the same output
# Ensure that the local time date formatters produce the same output
# wherever the test is run.
# wherever the test is run.
export
TZ
=
UTC
export
TZ
=
UTC
echo
"... no VSL args"
echo
"... no VSL args"
CKSUM
=
$(
../varnishevent
-r
${
IN
}
-f
${
CONF
}
-l
${
LOG
}
|
cksum
)
CKSUM
=
$(
../varnishevent
-r
${
IN
}
-f
${
CONF
}
-l
${
LOG
}
|
tee
${
TRC
}
.no |
cksum
)
if
[
"
$CKSUM
"
!=
'2542287168 442191'
]
;
then
if
[
"
$CKSUM
"
!=
'2542287168 442191'
]
;
then
echo
"ERROR: no VSL args unexpected cksum:
$CKSUM
"
echo
"ERROR: no VSL args unexpected cksum:
$CKSUM
"
...
@@ -21,7 +25,8 @@ if [ "$CKSUM" != '2542287168 442191' ]; then
...
@@ -21,7 +25,8 @@ if [ "$CKSUM" != '2542287168 442191' ]; then
fi
fi
echo
"... -g vxid"
echo
"... -g vxid"
CKSUM
=
$(
../varnishevent
-g
vxid
-r
${
IN
}
-f
${
CONF
}
-l
${
LOG
}
|
cksum
)
CKSUM
=
$(
../varnishevent
-g
vxid
-r
${
IN
}
-f
${
CONF
}
-l
${
LOG
}
|
tee
${
TRC
}
.vxid |
cksum
)
# Same as default (no -g arg)
# Same as default (no -g arg)
if
[
"
$CKSUM
"
!=
'2542287168 442191'
]
;
then
if
[
"
$CKSUM
"
!=
'2542287168 442191'
]
;
then
...
@@ -30,7 +35,8 @@ if [ "$CKSUM" != '2542287168 442191' ]; then
...
@@ -30,7 +35,8 @@ if [ "$CKSUM" != '2542287168 442191' ]; then
fi
fi
echo
"... -g request"
echo
"... -g request"
CKSUM
=
$(
../varnishevent
-g
request
-r
${
IN
}
-f
${
CONF
}
-l
${
LOG
}
|
cksum
)
CKSUM
=
$(
../varnishevent
-g
request
-r
${
IN
}
-f
${
CONF
}
-l
${
LOG
}
|
tee
${
TRC
}
.request |
cksum
)
if
[
"
$CKSUM
"
!=
'3970366484 443186'
]
;
then
if
[
"
$CKSUM
"
!=
'3970366484 443186'
]
;
then
echo
"ERROR: -g request unexpected cksum:
$CKSUM
"
echo
"ERROR: -g request unexpected cksum:
$CKSUM
"
...
@@ -42,7 +48,8 @@ echo "... -g raw"
...
@@ -42,7 +48,8 @@ echo "... -g raw"
# even for binary file reads. So we check against the last four columns.
# even for binary file reads. So we check against the last four columns.
# The query restricts output to Begin records; the previous invocation
# The query restricts output to Begin records; the previous invocation
# rendered every record with just the VXIDs.
# rendered every record with just the VXIDs.
CKSUM
=
$(
../varnishevent
-g
raw
-r
${
IN
}
-f
raw.conf
-l
${
LOG
}
-q
'Begin'
|
cut
-d
' '
-f4-
|
cksum
)
CKSUM
=
$(
../varnishevent
-g
raw
-r
${
IN
}
-f
raw.conf
-l
${
LOG
}
-q
'Begin'
|
cut
-d
' '
-f4-
|
tee
${
TRC
}
.raw |
cksum
)
if
[
"
$CKSUM
"
!=
'3267477005 21053'
]
;
then
if
[
"
$CKSUM
"
!=
'3267477005 21053'
]
;
then
echo
"ERROR: -g raw with query unexpected cksum:
$CKSUM
"
echo
"ERROR: -g raw with query unexpected cksum:
$CKSUM
"
...
@@ -66,7 +73,8 @@ if [ "$?" != "1" ]; then
...
@@ -66,7 +73,8 @@ if [ "$?" != "1" ]; then
fi
fi
echo
"... -q query"
echo
"... -q query"
CKSUM
=
$(
../varnishevent
-q
'ReqURL ~ "_static"'
-r
${
IN
}
-l
${
LOG
}
|
cksum
)
CKSUM
=
$(
../varnishevent
-q
'ReqURL ~ "_static"'
-r
${
IN
}
-l
${
LOG
}
|
tee
${
TRC
}
.query |
cksum
)
if
[
"
$CKSUM
"
!=
'805680033 830'
]
;
then
if
[
"
$CKSUM
"
!=
'805680033 830'
]
;
then
echo
"ERROR: -q query unexpected cksum:
$CKSUM
"
echo
"ERROR: -q query unexpected cksum:
$CKSUM
"
...
@@ -81,7 +89,8 @@ if [ "$?" != "1" ]; then
...
@@ -81,7 +89,8 @@ if [ "$?" != "1" ]; then
fi
fi
echo
"... -C"
echo
"... -C"
CKSUM
=
$(
../varnishevent
-C
-q
'ReqURL ~ "_STATIC"'
-r
${
IN
}
-l
${
LOG
}
|
cksum
)
CKSUM
=
$(
../varnishevent
-C
-q
'ReqURL ~ "_STATIC"'
-r
${
IN
}
-l
${
LOG
}
|
tee
${
TRC
}
.dash-C |
cksum
)
if
[
"
$CKSUM
"
!=
'805680033 830'
]
;
then
if
[
"
$CKSUM
"
!=
'805680033 830'
]
;
then
echo
"ERROR: -q query unexpected cksum:
$CKSUM
"
echo
"ERROR: -q query unexpected cksum:
$CKSUM
"
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment