r3619 - in branches/2.0/varnish-cache: bin/varnishd man

tfheen at projects.linpro.no tfheen at projects.linpro.no
Thu Feb 5 12:57:13 CET 2009


Author: tfheen
Date: 2009-02-05 12:57:13 +0100 (Thu, 05 Feb 2009)
New Revision: 3619

Modified:
   branches/2.0/varnish-cache/bin/varnishd/mgt_param.c
   branches/2.0/varnish-cache/bin/varnishd/varnishd.1
   branches/2.0/varnish-cache/man/vcl.7so
Log:
Merge r3411+r3412: Added documentaiton on the timeouts



Modified: branches/2.0/varnish-cache/bin/varnishd/mgt_param.c
===================================================================
--- branches/2.0/varnish-cache/bin/varnishd/mgt_param.c	2009-02-05 11:51:20 UTC (rev 3618)
+++ branches/2.0/varnish-cache/bin/varnishd/mgt_param.c	2009-02-05 11:57:13 UTC (rev 3619)
@@ -773,11 +773,11 @@
 		"off", "bool" },
 	{ "connect_timeout", tweak_timeout_double,
 		&master.connect_timeout,0, UINT_MAX,
-		"Default connection timeout for backend connections.  "
+		"Default connection timeout for backend connections. "
 		"We only try to connect to the backend for this many "
 		"seconds before giving up. "
-		"VCL can override this default value for each backend. "
-		"This does not apply to pipe. ",
+		"VCL can override this default value for each backend and "
+		"backend request.",
 		0,
 		"0.4", "s" },
 	{ "first_byte_timeout", tweak_timeout_double,
@@ -785,7 +785,8 @@
 		"Default timeout for receiving first byte from backend. "
 		"We only wait for this many seconds for the first "
 		"byte before giving up. A value of 0 means it will never time out. "
-		"VCL can override this default value for each backend request.",
+		"VCL can override this default value for each backend and "
+		"backend request. This parameter does not apply to pipe.",
 		0,
 		"60", "s" },
 	{ "between_bytes_timeout", tweak_timeout_double,
@@ -793,7 +794,8 @@
 		"Default timeout between bytes when receiving data from backend. "
 		"We only wait for this many seconds between bytes "
 		"before giving up. A value of 0 means it will never time out. "
-		"VCL can override this default value for each backend request.",
+		"VCL can override this default value for each backend request and "
+		"backend request. This parameter does not apply to pipe.",
 		0,
 		"60", "s" },
 	{ "accept_fd_holdoff", tweak_timeout,

Modified: branches/2.0/varnish-cache/bin/varnishd/varnishd.1
===================================================================
--- branches/2.0/varnish-cache/bin/varnishd/varnishd.1	2009-02-05 11:51:20 UTC (rev 3618)
+++ branches/2.0/varnish-cache/bin/varnishd/varnishd.1	2009-02-05 11:57:13 UTC (rev 3619)
@@ -405,6 +405,15 @@
 .Pp
 The default is
 .Dv off .
+.It Va between_bytes_timeout
+Default timeout between bytes when receiving data from backend.
+We only wait for this many seconds between bytes before giving up.
+A value of 0 means it will never time out.
+VCL can override this default value for each backend and backend request.
+This parameter does not apply to pipe.
+.Pp
+The default is
+.Dv 60 seconds
 .It Va client_http11
 Whether to force the use of HTTP/1.1 when responding to client
 requests, or just use the same protocol version as that used by the
@@ -412,6 +421,13 @@
 .Pp
 The default is
 .Dv off .
+.It Va connect_timeout
+Default connection timeout for backend connections.
+We only try to connect to the backend for this many seconds before giving up.
+VCL can override this default value for each backend and backend request.
+.Pp
+The default is
+.Dv 0.4 seconds
 .It Va default_ttl
 The default time-to-live assigned to objects if neither the backend
 nor the configuration assign one.
@@ -427,6 +443,15 @@
 backend server does not specify a content length.
 .Pp
 The default is 128 kilobytes.
+.It Va first_byte_timeout
+Default timeout for receiving first byte from backend.
+We only wait for this many seconds for the first byte before giving up.
+A value of 0 means it will never time out.
+VCL can override this default value for each backend and backend request.
+This parameter does not apply to pipe.
+.Pp
+The default is
+.Dv 60 seconds
 .It Va group
 The name of an unprivileged group to which the child process should
 switch before it starts accepting connections.

Modified: branches/2.0/varnish-cache/man/vcl.7so
===================================================================
--- branches/2.0/varnish-cache/man/vcl.7so	2009-02-05 11:51:20 UTC (rev 3618)
+++ branches/2.0/varnish-cache/man/vcl.7so	2009-02-05 11:57:13 UTC (rev 3619)
@@ -92,6 +92,26 @@
     set req.backend = www;
 }
 .Ed
+.Pp
+The timeout parameters can be overridden in the backend declaration.
+The timeout parameters are
+.Fa .connect_timeout
+for the time to wait for a backend connection,
+.Fa .first_byte_timeout
+for the time to wait for the first byte from the backend and
+.Fa .between_bytes_timeout
+for time to wait between each received byte.
+.Pp
+These can be set in the declaration like this:
+.Bd -literal -offset 4n
+backend www {
+    .host = "www.example.com";
+    .port = "http";
+    .connect_timeout = 1s;
+    .first_byte_timeout = 5s;
+    .between_bytes_timeout = 2s;
+}
+.Ed
 .Ss Directors
 Directors choose from different backends based on health status and a
 per-director algorithm.
@@ -516,6 +536,14 @@
 .It Va bereq.http. Ns Ar header
 The corresponding HTTP
 .Ar header .
+.It Va bereq.connect_timeout
+The time in seconds to wait for a backend connection.
+.It Va bereq.first_byte_timeout
+The time in seconds to wait for the first byte from the backend.
+Not available in pipe mode.
+.It Va bereq.between_bytes_timeout
+The time in seconds to wait between each received byte from the backend.
+Not available in pipe mode.
 .El
 .Pp
 The following variables are available after the requested object has



More information about the varnish-commit mailing list