Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
O
oob_probe
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
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
oob_probe
Commits
f7cc95cd
Commit
f7cc95cd
authored
Oct 24, 2015
by
Geoff Simmons
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
add tests adapted from Varnish c00017.vtc
parent
cb1ab96f
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
104 additions
and
0 deletions
+104
-0
test03.vtc
src/tests/test03.vtc
+52
-0
test04.vtc
src/tests/test04.vtc
+52
-0
No files found.
src/tests/test03.vtc
0 → 100644
View file @
f7cc95cd
varnishtest "Test Backend Polling with an out-of-band port (cf. c00017.vtc)"
server s1 {} -start
server s2 {
# Probes
loop 8 {
rxreq
expect req.url == "/"
txresp -hdr "Bar: foo" -body "foobar"
accept
}
loop 3 {
rxreq
expect req.url == "/"
txresp -status 404 -hdr "Bar: foo" -body "foobar"
accept
}
loop 2 {
rxreq
expect req.url == "/"
txresp -proto "FROBOZ" -status 200 -hdr "Bar: foo" -body "foobar"
accept
}
sema r1 sync 2
} -start
varnish v1 -vcl {
import oob_probe from "${vmod_topbuild}/src/.libs/libvmod_oob_probe.so";
probe p {
.timeout = 1 s;
.interval = 0.1 s;
}
backend foo {
.host = "${s1_addr}";
.port = "${s1_port}";
}
sub vcl_init {
oob_probe.port(foo, p, "${s2_port}");
}
} -start
sema r1 sync 2
varnish v1 -cli "backend.list -p"
src/tests/test04.vtc
0 → 100644
View file @
f7cc95cd
varnishtest "Test Backend Polling with an out-of-band port (cf. c00017.vtc)"
server s1 {} -start
server s2 {
# Probes
loop 8 {
rxreq
expect req.url == "/"
txresp -hdr "Bar: foo" -body "foobar"
accept
}
loop 3 {
rxreq
expect req.url == "/"
txresp -status 404 -hdr "Bar: foo" -body "foobar"
accept
}
loop 2 {
rxreq
expect req.url == "/"
txresp -proto "FROBOZ" -status 200 -hdr "Bar: foo" -body "foobar"
accept
}
sema r1 sync 2
} -start
varnish v1 -vcl {
import oob_probe from "${vmod_topbuild}/src/.libs/libvmod_oob_probe.so";
probe p {
.timeout = 1 s;
.interval = 0.1 s;
}
backend foo {
.host = "${s1_addr}";
.port = "${s1_port}";
}
sub vcl_init {
oob_probe.addr(foo, p, "${s2_addr}", "${s2_port}");
}
} -start
sema r1 sync 2
varnish v1 -cli "backend.list -p"
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