[master] 92d71fb s/req.backend/req.backend_hint/g

Lasse Karstensen lkarsten at varnish-software.com
Thu Feb 27 10:34:41 CET 2014


commit 92d71fb8eeaf5d7e8599c7ecb90da6f603d0941c
Author: Lasse Karstensen <lkarsten at varnish-software.com>
Date:   Wed Feb 26 13:12:59 2014 +0100

    s/req.backend/req.backend_hint/g

diff --git a/doc/sphinx/reference/vcl.rst b/doc/sphinx/reference/vcl.rst
index 436d58d..57072d0 100644
--- a/doc/sphinx/reference/vcl.rst
+++ b/doc/sphinx/reference/vcl.rst
@@ -35,7 +35,7 @@ A backend declaration creates and initializes a named backend object::
 The backend object can later be used to select a backend at request time::
 
     if (req.http.host ~ "(?i)^(www.)?example.com$") {
-        set req.backend = www;
+        set req.backend_hint = www;
     }
 
 To avoid overloading backend servers, .max_connections can be set to
diff --git a/doc/sphinx/users-guide/devicedetection.rst b/doc/sphinx/users-guide/devicedetection.rst
index c7acd73..e60b438 100644
--- a/doc/sphinx/users-guide/devicedetection.rst
+++ b/doc/sphinx/users-guide/devicedetection.rst
@@ -229,7 +229,7 @@ special needs in VCL, you can use the X-UA-Device header like this::
         # call some detection engine
 
         if (req.http.X-UA-Device ~ "^mobile" || req.http.X-UA-device ~ "^tablet") {
-            set req.backend = mobile;
+            set req.backend_hint = mobile;
         }
     }
     sub vcl_hash {
diff --git a/doc/sphinx/users-guide/vcl-backends.rst b/doc/sphinx/users-guide/vcl-backends.rst
index 6e72416..099e2a6 100644
--- a/doc/sphinx/users-guide/vcl-backends.rst
+++ b/doc/sphinx/users-guide/vcl-backends.rst
@@ -62,9 +62,9 @@ Now we need tell where to send the difference URL. Lets look at vcl_recv.::
 
     sub vcl_recv {
         if (req.url ~ "^/java/") {
-            set req.backend = java;
+            set req.backend_hint = java;
         } else {
-            set req.backend = default.
+            set req.backend_hint = default.
         }
     }
 
@@ -88,9 +88,9 @@ You can have something like this:::
 
     sub vcl_recv {
         if (req.http.host ~ "foo.com") {
-            set req.backend = foo;
+            set req.backend_hint = foo;
         } elsif (req.http.host ~ "bar.com") {
-            set req.backend = bar;
+            set req.backend_hint = bar;
         }
     }
 
@@ -101,7 +101,7 @@ more tight, maybe relying on the == operator in stead, like this:::
 
     sub vcl_recv {
         if (req.http.host == "foo.com" or req.http.host == "www.foo.com") {
-            set req.backend = foo;
+            set req.backend_hint = foo;
         }
     }
 
@@ -138,7 +138,7 @@ call certain actions in vcl_init.::
 
     sub vcl_recv {
         # send all traffic to the bar director:
-        req.backend = bar.backend();
+        req.backend_hint = bar.backend();
     }
 
 This director is a round-robin director. This means the director will
diff --git a/doc/sphinx/whats-new/upgrading.rst b/doc/sphinx/whats-new/upgrading.rst
index 97e3a0d..68a41d0 100644
--- a/doc/sphinx/whats-new/upgrading.rst
+++ b/doc/sphinx/whats-new/upgrading.rst
@@ -32,7 +32,7 @@ Since the client director was already a special case of the hash director, it ha
 	}
 
 	sub vcl_recv {
-		set req.backend = h.backend(client.ip);
+		set req.backend_hint = h.backend(client.ip);
 	}
 
 error() is now a return value



More information about the varnish-commit mailing list