You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@trafficserver.apache.org by bc...@apache.org on 2015/08/25 22:34:02 UTC

[1/2] trafficserver git commit: TS-3820 Change the default for proxy.config.http.redirect_host_no_port

Repository: trafficserver
Updated Branches:
  refs/heads/6.0.x 8e49ab9e0 -> a95b721b7


TS-3820 Change the default for proxy.config.http.redirect_host_no_port

This will now enable this feature by default, and therefore, should
also be backported to 6.0.0. The point of this option is to avoid
adding the port to the redirected host, unless required. This is
already standard ATS practices, and we made this option to be
backwards compatible. I think for 7.0.0, we should simply remove
this option completely unless someone is using it still at that
point.

(cherry picked from commit 7d15f72c0798a8599eab201d16e5b5e9e16a6c71)


Project: http://git-wip-us.apache.org/repos/asf/trafficserver/repo
Commit: http://git-wip-us.apache.org/repos/asf/trafficserver/commit/a1c5b9b3
Tree: http://git-wip-us.apache.org/repos/asf/trafficserver/tree/a1c5b9b3
Diff: http://git-wip-us.apache.org/repos/asf/trafficserver/diff/a1c5b9b3

Branch: refs/heads/6.0.x
Commit: a1c5b9b37eb0a6fc756841a6bc57b04a81a43560
Parents: 8e49ab9
Author: Leif Hedstrom <zw...@apache.org>
Authored: Tue Aug 18 09:14:34 2015 -0600
Committer: Bryan Call <bc...@apache.org>
Committed: Tue Aug 25 13:33:10 2015 -0700

----------------------------------------------------------------------
 mgmt/RecordsConfig.cc   | 2 +-
 proxy/http/HttpConfig.h | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/trafficserver/blob/a1c5b9b3/mgmt/RecordsConfig.cc
----------------------------------------------------------------------
diff --git a/mgmt/RecordsConfig.cc b/mgmt/RecordsConfig.cc
index e1c48c1..abf4b8f 100644
--- a/mgmt/RecordsConfig.cc
+++ b/mgmt/RecordsConfig.cc
@@ -169,7 +169,7 @@ static const RecordElement RecordsConfig[] =
   ,
   {RECT_CONFIG, "proxy.config.http.number_of_redirections", RECD_INT, "1", RECU_DYNAMIC, RR_NULL, RECC_NULL, NULL, RECA_NULL}
   ,
-  {RECT_CONFIG, "proxy.config.http.redirect_host_no_port", RECD_INT, "0", RECU_DYNAMIC, RR_NULL, RECC_NULL, NULL, RECA_NULL}
+  {RECT_CONFIG, "proxy.config.http.redirect_host_no_port", RECD_INT, "1", RECU_DYNAMIC, RR_NULL, RECC_NULL, NULL, RECA_NULL}
   ,
   {RECT_CONFIG, "proxy.config.http.post_copy_size", RECD_INT, "2048", RECU_NULL, RR_NULL, RECC_NULL, NULL, RECA_NULL}
   ,

http://git-wip-us.apache.org/repos/asf/trafficserver/blob/a1c5b9b3/proxy/http/HttpConfig.h
----------------------------------------------------------------------
diff --git a/proxy/http/HttpConfig.h b/proxy/http/HttpConfig.h
index cd2cb75..3f4c863 100644
--- a/proxy/http/HttpConfig.h
+++ b/proxy/http/HttpConfig.h
@@ -851,7 +851,7 @@ inline HttpConfigParams::HttpConfigParams()
     cache_vary_default_other(NULL), max_cache_open_write_retries(1), cache_enable_default_vary_headers(0), cache_post_method(0),
     connect_ports_string(NULL), connect_ports(NULL), push_method_enabled(0), referer_filter_enabled(0), referer_format_redirect(0),
     reverse_proxy_enabled(0), url_remap_required(1), record_cop_page(0), errors_log_error_pages(1), enable_http_info(0),
-    cluster_time_delta(0), redirection_enabled(0), redirection_host_no_port(0), number_of_redirections(1), post_copy_size(2048),
+    cluster_time_delta(0), redirection_enabled(0), redirection_host_no_port(1), number_of_redirections(1), post_copy_size(2048),
     ignore_accept_mismatch(0), ignore_accept_language_mismatch(0), ignore_accept_encoding_mismatch(0),
     ignore_accept_charset_mismatch(0), send_100_continue_response(0), disallow_post_100_continue(0), parser_allow_non_http(1),
     cache_open_write_fail_action(0), max_post_size(0), server_session_sharing_pool(TS_SERVER_SESSION_SHARING_POOL_THREAD),


[2/2] trafficserver git commit: [TS-3820] Docs for the redirection settings.

Posted by bc...@apache.org.
[TS-3820] Docs for the redirection settings.

(cherry picked from commit 9ee6274f3539a7fccd1eae6965eba70d33173498)


Project: http://git-wip-us.apache.org/repos/asf/trafficserver/repo
Commit: http://git-wip-us.apache.org/repos/asf/trafficserver/commit/a95b721b
Tree: http://git-wip-us.apache.org/repos/asf/trafficserver/tree/a95b721b
Diff: http://git-wip-us.apache.org/repos/asf/trafficserver/diff/a95b721b

Branch: refs/heads/6.0.x
Commit: a95b721b70afc14db078ee1ba17a47560354ee4e
Parents: a1c5b9b
Author: Sudheer Vinukonda <su...@yahoo-inc.com>
Authored: Wed Aug 19 00:17:43 2015 +0000
Committer: Bryan Call <bc...@apache.org>
Committed: Tue Aug 25 13:33:11 2015 -0700

----------------------------------------------------------------------
 .../configuration/records.config.en.rst          | 19 +++++++++++++++++++
 1 file changed, 19 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/trafficserver/blob/a95b721b/doc/reference/configuration/records.config.en.rst
----------------------------------------------------------------------
diff --git a/doc/reference/configuration/records.config.en.rst b/doc/reference/configuration/records.config.en.rst
index 257e070..5070589 100644
--- a/doc/reference/configuration/records.config.en.rst
+++ b/doc/reference/configuration/records.config.en.rst
@@ -1029,6 +1029,25 @@ The default value of ``0`` specifies that there is no timeout.
    The proportion of total document size already transferred when a client aborts at which the proxy continues fetching the document
    from the origin server to get it into the cache (a **background fill**).
 
+HTTP Redirection
+================
+
+.. ts:cv:: CONFIG proxy.config.http.redirection_enabled INT 0
+
+   This setting indicates whether Trafficserver does a redirect follow location on receiving a 3XX Redirect response from the Origin
+   server. The redirection attempt is transparent to the client and the client is served the final response from the redirected-to
+   location.
+
+.. ts:cv:: CONFIG proxy.config.http.number_of_redirections INT 1
+
+   This setting determines the maximum number of times Trafficserver does a redirect follow location on receiving a 3XX Redirect response
+   for a given client request.
+
+.. ts:cv:: CONFIG proxy.config.http.redirect_host_no_port INT 1
+
+   This setting enables Trafficserver to not include the port in the Host header in the redirect follow request for default/standard ports
+   (e.g. 80 for HTTP and 443 for HTTPS). Note that the port is still included in the Host header if it's non-default.
+
 Origin Server Connect Attempts
 ==============================