Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
V
varnish-cache
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Commits
Open sidebar
varnishcache
varnish-cache
Commits
349256d6
Commit
349256d6
authored
Feb 24, 2014
by
Federico G. Schwindt
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Sync with vmod.vcc
parent
2d1a8c11
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
21 additions
and
4 deletions
+21
-4
vmod_std.rst
doc/sphinx/reference/vmod_std.rst
+21
-4
No files found.
doc/sphinx/reference/vmod_std.rst
View file @
349256d6
...
...
@@ -23,7 +23,7 @@ DESCRIPTION
Vmod_std contains basic functions which are part and parcel of Varnish,
but which for reasons of architecture fit better in a VMOD.
One
specific
class of functions in vmod_std is the conversions functions
One
particular
class of functions in vmod_std is the conversions functions
which all have the form::
TYPE type(STRING, TYPE)
...
...
@@ -127,9 +127,10 @@ duration
Prototype
DURATION duration(STRING s, DURATION fallback)
Description
Converts the string *s* to seconds. *s* can be quantified with
the usual s (seconds), m (minutes), h (hours), d (days) and w
(weeks) units. If *s* fails to parse, *fallback* will be returned.
Converts the string *s* to seconds. *s* must be quantified
with ms (milliseconds), s (seconds), m (minutes), h (hours),
d (days) or w (weeks) units. If *s* fails to parse,
*fallback* will be returned.
Example
set beresp.ttl = std.duration("1w", 3600s);
...
...
@@ -154,6 +155,22 @@ Description
Example
if (std.ip(req.http.X-forwarded-for, "0.0.0.0") ~ my_acl) { ... }
healthy
-------
Prototype
BOOL healthy(BACKEND backend)
Description
Returns true if the backend is healthy.
port
----
Prototype
INT port(IP ip)
Description
Returns the port number of an IP address.
SEE ALSO
========
...
...
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