Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
L
libvmod-cluster
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
libvmod-cluster
Commits
f62d77b3
Commit
f62d77b3
authored
Mar 20, 2019
by
Nils Goroll
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
improve doc
parent
ffe83545
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
20 additions
and
1 deletion
+20
-1
vmod_cluster.vcc
src/vmod_cluster.vcc
+20
-1
No files found.
src/vmod_cluster.vcc
View file @
f62d77b3
...
...
@@ -22,6 +22,9 @@ backend. Otherwise, the request is to be forwarded to another node
from the `cluster` argument, which, in turn, will either serve the
object from its cache or issue a request against a `real` backend.
Introductory configuration example
----------------------------------
For a shard director argument ``shard``, the following examples are
roughly equivalent if ``myself`` resolves to the local node
...
...
@@ -61,7 +64,7 @@ roughly equivalent if ``myself`` resolves to the local node
Differences between the two methods are:
* the cluster director
works
with lazy resolution where a director
* the cluster director
can work
with lazy resolution where a director
does not return one of its configured backends, but rather a
reference to itself (as do all the varnish bundled directors except
for the shard director, which supports lazy resolution with the
...
...
@@ -75,6 +78,22 @@ Differences between the two methods are:
Simply put, when using the cluster director, the ``.set_real()``
method effectively replaces ``set bereq.backend``.
Real life example
-----------------
As-is, the simplified example given above will run all VCL code on all
varnish servers of the cluster. This works well if VCL is written
idempotent, but as common VCL is not, we are providing a VCL library
and a template example for a cluster setup in the *vcl/* and
*example/* subdirectory of the source tree.
There also is a shell-script to set up a basic demo.
``vshard.inc.vcl`` provides four vcl subs to be called at the
beginning of the main vcl subs as shown in ``vshard.example.vcl``. The
example should hopefully be self explanatory.
.. _meth_ctx:
Method Behavior in Different VCL Subs
...
...
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