Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
L
libvdp-pesi
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Jobs
Commits
Open sidebar
uplex-varnish
libvdp-pesi
Commits
6af28b5d
Unverified
Commit
6af28b5d
authored
May 10, 2023
by
Nils Goroll
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Extend backend timeout test
parent
b97ce3f3
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
23 additions
and
5 deletions
+23
-5
backend_timeout.vtc
src/tests/backend_timeout.vtc
+23
-5
No files found.
src/tests/backend_timeout.vtc
View file @
6af28b5d
...
...
@@ -7,7 +7,8 @@ server s1 {
txresp -body {
<html>
Before include
<esi:include
src=
"/body"
sr=
"foo"
/>
<esi:include
src=
"/bodyA"
sr=
"foo"
/>
<esi:include
src=
"/bodyB"
/>
After include
</html>
}
...
...
@@ -15,7 +16,7 @@ server s1 {
server s2 {
rxreq
expect req.url == "/body1"
expect req.url == "/body
A
1"
expect req.http.esi0 != "foo"
delay 0.6
txresp -body {
...
...
@@ -23,6 +24,16 @@ server s2 {
}
} -start
server s3 {
rxreq
expect req.url == "/bodyB1"
expect req.http.esi0 != "foo"
txresp -hdr "Transfer-encoding: chunked"
chunked "Included"
delay 0.4
expect_close
} -start
varnish v1 -vcl+backend {
import ${vmod_pesi};
import ${vmod_pesi_debug};
...
...
@@ -39,10 +50,16 @@ varnish v1 -vcl+backend {
sub vcl_backend_fetch {
if (bereq.url == "/") {
set bereq.backend = s1;
}
else
{
}
else
if (bereq.url == "/bodyA1")
{
set bereq.backend = s2;
set bereq.first_byte_timeout = 0.5s;
} else
if (bereq.url == "/bodyB1") {
set bereq.backend = s3;
set bereq.between_bytes_timeout = 0.3s;
} else {
return (abandon);
}
}
...
...
@@ -66,11 +83,12 @@ client c1 {
txreq -hdr "Host: foo"
rxresp
expect resp.status == 200
expect resp.bodylen ==
62
expect resp.bodylen ==
73
expect resp.body == {
<html>
Before include
ouch!
Included
After include
</html>
}
...
...
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