mlibbey commented on code in PR #12174:
URL: https://github.com/apache/trafficserver/pull/12174#discussion_r2035969419
##########
doc/admin-guide/plugins/header_rewrite.en.rst:
##########
@@ -958,7 +958,11 @@ changing the remapped destination, ``<part>`` should be
used to indicate the
component that is being modified (see `URL Parts`_), and ``<value>`` will be
used as its replacement. You must supply a non-zero length value, otherwise
this operator will be an effective no-op (though a warning will be emitted to
-the logs if debugging is enabled).
+the logs if debugging is enabled). Also, note that for ``PATH`` ``<part>``
+values, a leading ``/`` is not included. That is, you will generally not want
+to start your ``PATH`` value with a leading ``/``. See the ``set-destination``
Review Comment:
Perhaps ``` `Prepend a Path to the URL`_ ``` (instead of set-destination)
so that we get a direct link to it? (and if there become multiple set-dest
examples, this will be clearer).
##########
doc/admin-guide/plugins/header_rewrite.en.rst:
##########
@@ -958,7 +958,11 @@ changing the remapped destination, ``<part>`` should be
used to indicate the
component that is being modified (see `URL Parts`_), and ``<value>`` will be
used as its replacement. You must supply a non-zero length value, otherwise
this operator will be an effective no-op (though a warning will be emitted to
-the logs if debugging is enabled).
+the logs if debugging is enabled). Also, note that for ``PATH`` ``<part>``
+values, a leading ``/`` is not included. That is, you will generally not want
+to start your ``PATH`` value with a leading ``/``. See the ``set-destination``
+example in the ``Examples`` section below for a demonstration of a ``PATH``
Review Comment:
perhaps ``` `Examples`_ ``` to get a link to the section?
##########
doc/admin-guide/plugins/header_rewrite.en.rst:
##########
@@ -1541,8 +1545,17 @@ could each be tagged with a consistent name to make
finding logs easier.::
sometimes avoid setting internal ``@`` headers for passing information
between hooks.
These internal state variables are much more efficient than setting and
reading headers.
+Prepend a Path to the URL
+-------------------------
+
+The following prepends ``/foo/bar`` to the URL path. Note that since ``PATH``
is
+non-inclusive of the initial ``/``, the provided prefix does not start with a
``/``::
Review Comment:
This was confusing to me -- the literal string PATH in the example versus
the concept of PATH. I think I would be less confused if we add "but, it does
end with a trailing /". Eg, if the url is example.com/example/ then providing
foo/bar/%{CLIENT-URL:PATH} will yield example.com/foo/bar/example/ (and
foo/bar%{CLIENT-URL:PATH} will yield example.com/foo/barexample/)
##########
doc/admin-guide/plugins/header_rewrite.en.rst:
##########
@@ -1541,8 +1545,17 @@ could each be tagged with a consistent name to make
finding logs easier.::
sometimes avoid setting internal ``@`` headers for passing information
between hooks.
These internal state variables are much more efficient than setting and
reading headers.
+Prepend a Path to the URL
+-------------------------
+
+The following prepends ``/foo/bar`` to the URL path. Note that since ``PATH``
is
Review Comment:
This should be ``/foo/bar/`` (with the trailing slash)
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]