Permalink
Browse files

updated the documentation to reflect recent changes.

  • Loading branch information...
1 parent 3641ccf commit 2cbbc15d68cdb99475a68b687223ba250c395b9e @agentzh agentzh committed Jan 25, 2011
Showing with 57 additions and 40 deletions.
  1. +35 −21 README
  2. +22 −19 doc/readme.wiki
View
56 README
@@ -6,9 +6,9 @@ Name
installation instructions.
Version
- This document describes headers-more-nginx-module v0.13
- (<http://github.com/agentzh/headers-more-nginx-module/tarball/v0.13 >)
- released on July 7, 2010.
+ This document describes headers-more-nginx-module v0.14
+ (<http://github.com/agentzh/headers-more-nginx-module/downloads >)
+ released on January 25, 2011.
Synopsis
# set the Server output header
@@ -67,8 +67,8 @@ Description
}
The option "-t" is also available in the more_set_input_headers and
- more_clear_input_headers directives while the "-s" option is not
- allowed.
+ more_clear_input_headers directives (for request header filtering) while
+ the "-s" option is not allowed.
Unlike the standard headers module, this module's directives will by
default apply to all the status codes, including "4xx" and "5xx".
@@ -80,7 +80,7 @@ Directives
default: *no*
- context: *http, server, location, locatoin if*
+ context: *http, server, location, location if*
Adds or replaces the specified output headers when the response status
code matches the codes specified by the "-s" option *AND* the response
@@ -229,12 +229,12 @@ Limitations
Installation
Grab the nginx source code from nginx.net (<http://nginx.net/ >), for
- example, the version 0.8.29 (see nginx compatibility), and then build
+ example, the version 0.8.54 (see nginx compatibility), and then build
the source with this module:
- $ wget 'http://sysoev.ru/nginx/nginx-0.8.29.tar.gz'
- $ tar -xzvf nginx-0.8.29.tar.gz
- $ cd nginx-0.8.29/
+ $ wget 'http://sysoev.ru/nginx/nginx-0.8.54.tar.gz'
+ $ tar -xzvf nginx-0.8.54.tar.gz
+ $ cd nginx-0.8.54/
# Here we assume you would install you nginx under /opt/nginx/.
$ ./configure --prefix=/opt/nginx \
@@ -250,9 +250,11 @@ Installation
Compatibility
The following versions of Nginx should work with this module:
- * 0.8.x (last tested: 0.8.53)
+ * 0.9.x (last tested: 0.9.4)
+
+ * 0.8.x (last tested: 0.8.54)
- * 0.7.x >= 0.7.44 (last tested: 0.7.67)
+ * 0.7.x >= 0.7.44 (last tested: 0.7.68)
Earlier versions of Nginx like 0.6.x and 0.5.x will *not* work.
@@ -275,6 +277,19 @@ Source Repository
(<http://github.com/agentzh/headers-more-nginx-module >).
ChangeLog
+ v0.14
+ * now we postpone the rewrite phase handler only once rather than on
+ every main request previously. this will save some CPU cycles on
+ every request if more_set_input_headers or more_clear_input_headers
+ are used.
+
+ * fixed two spots where we did not check against null pointers when
+ out of memory.
+
+ * now we use the 2-clause bsd license instead.
+
+ * various coding style fixes.
+
v0.13
* fixed a bug in rewrite phase postponing algorithm which may cause
ngx_eval (<http://www.grid.net.ru/nginx/eval.en.html >)'s eval block
@@ -331,13 +346,11 @@ Test Suite
To run it on your side:
- $ cd test
$ PATH=/path/to/your/nginx-with-headers-more-module:$PATH prove -r t
To run the test suite with valgrind's memcheck, use the following
commands:
- $ cd test
$ export PATH=/path/to/your/nginx-with-headers-more-module:$PATH
$ TEST_NGINX_USE_VALGRIND=1 prove -r t
@@ -371,12 +384,13 @@ Copyright & License
The code base is borrowed directly from the standard headers module in
Nginx 0.8.24. This part of code is copyrighted by Igor Sysoev.
- Copyright (c) 2009-2010, Taobao Inc., Alibaba Group (
+ Copyright (c) 2009, 2010, 2011, Taobao Inc., Alibaba Group (
http://www.taobao.com ).
- Copyright (c) 2009-2010, agentzh <agentzh@gmail.com>.
+ Copyright (c) 2009, 2010, 2011, Yichun "agentzh" Zhang (章亦春)
+ <agentzh@gmail.com>.
- Copyright (c) 2010, Bernd Dorn.
+ Copyright (c) 2010, 2011, Bernd Dorn.
This module is licensed under the terms of the BSD license.
@@ -406,15 +420,15 @@ Copyright & License
See Also
* The original thread on the Nginx mailing list that inspires this
module's development: "A question about add_header replication"
- (<http://www.pubbs.net/nginx/200910/6361/ >).
+ (<http://forum.nginx.org/read.php?2,11206,11738 >).
* The orginal announcement thread on the Nginx mailing list: "The
"headers_more" module: Set and clear output headers...more than
- 'add'!" (<http://www.pubbs.net/nginx/200911/29942/ >).
+ 'add'!" (<http://forum.nginx.org/read.php?2,23460 >).
* The original blog post
- (<http://agentzh.spaces.live.com/blog/cns!FF3A735632E41548!482.entry
- >) about this module's initial development.
+ (<http://agentzh.blogspot.com/2009/11/headers-more-module-scripting-
+ input-and.html>) about this module's initial development.
* The echo module for Nginx module's automated testing.
View
@@ -6,7 +6,7 @@
= Version =
-This document describes headers-more-nginx-module [http://github.com/agentzh/headers-more-nginx-module/tarball/v0.13 v0.13] released on July 7, 2010.
+This document describes headers-more-nginx-module [http://github.com/agentzh/headers-more-nginx-module/downloads v0.14] released on January 25, 2011.
= Synopsis =
@@ -76,7 +76,7 @@ Input headers can be modified as well. For example
The option <code>-t</code> is also available in the
[[#more_set_input_headers|more_set_input_headers]] and
-[[#more_clear_input_headers|more_clear_input_headers]] directives while the <code>-s</code> option
+[[#more_clear_input_headers|more_clear_input_headers]] directives (for request header filtering) while the <code>-s</code> option
is not allowed.
Unlike the standard [[NginxHttpHeadersModule|headers]] module, this module's directives will by
@@ -89,7 +89,7 @@ default apply to all the status codes, including <code>4xx</code> and <code>5xx<
'''default:''' ''no''
-'''context:''' ''http, server, location, locatoin if''
+'''context:''' ''http, server, location, location if''
Adds or replaces the specified output headers when the response status code matches the codes specified by the <code>-s</code> option ''AND'' the response content type matches the types specified by the <code>-t</code> option.
@@ -238,12 +238,12 @@ See [[#more_set_input_headers|more_set_input_headers]] for more details.
= Installation =
Grab the nginx source code from [http://nginx.net/ nginx.net], for example,
-the version 0.8.29 (see [[#Compatibility|nginx compatibility]]), and then build the source with this module:
+the version 0.8.54 (see [[#Compatibility|nginx compatibility]]), and then build the source with this module:
<geshi lang="bash">
- $ wget 'http://sysoev.ru/nginx/nginx-0.8.29.tar.gz'
- $ tar -xzvf nginx-0.8.29.tar.gz
- $ cd nginx-0.8.29/
+ $ wget 'http://sysoev.ru/nginx/nginx-0.8.54.tar.gz'
+ $ tar -xzvf nginx-0.8.54.tar.gz
+ $ cd nginx-0.8.54/
# Here we assume you would install you nginx under /opt/nginx/.
$ ./configure --prefix=/opt/nginx \
@@ -259,8 +259,9 @@ Download the latest version of the release tarball of this module from [http://g
The following versions of Nginx should work with this module:
-* '''0.8.x''' (last tested: 0.8.53)
-* '''0.7.x >= 0.7.44''' (last tested: 0.7.67)
+* '''0.9.x''' (last tested: 0.9.4)
+* '''0.8.x''' (last tested: 0.8.54)
+* '''0.7.x >= 0.7.44''' (last tested: 0.7.68)
Earlier versions of Nginx like 0.6.x and 0.5.x will ''not'' work.
@@ -279,6 +280,12 @@ Available on github at [http://github.com/agentzh/headers-more-nginx-module agen
= ChangeLog =
+== v0.14 ==
+* now we postpone the rewrite phase handler only once rather than on every main request previously. this will save some CPU cycles on every request if [[#more_set_input_headers|more_set_input_headers]] or [[#more_clear_input_headers|more_clear_input_headers]] are used.
+* fixed two spots where we did not check against null pointers when out of memory.
+* now we use the 2-clause bsd license instead.
+* various coding style fixes.
+
== v0.13 ==
* fixed a bug in rewrite phase postponing algorithm which may cause [http://www.grid.net.ru/nginx/eval.en.html ngx_eval]'s eval block running ''after'' [http://wiki.nginx.org/NginxHttpRewriteModule ngx_rewrite]'s directives. thanks Liseen Wan (xunxin).
@@ -315,19 +322,16 @@ This module comes with a Perl-driven test suite. The [http://github.com/agentzh/
To run it on your side:
<geshi lang="bash">
- $ cd test
$ PATH=/path/to/your/nginx-with-headers-more-module:$PATH prove -r t
</geshi>
To run the test suite with valgrind's memcheck, use the following commands:
<geshi lang="bash">
- $ cd test
$ export PATH=/path/to/your/nginx-with-headers-more-module:$PATH
$ TEST_NGINX_USE_VALGRIND=1 prove -r t
</geshi>
-
You need to terminate any Nginx processes before running the test suite if you have changed the Nginx server binary.
Because a single nginx server (by default, <code>localhost:1984</code>) is used across all the test scripts (<code>.t</code> files), it's meaningless to run the test suite in parallel by specifying <code>-jN</code> when invoking the <code>prove</code> utility.
@@ -354,11 +358,11 @@ This wiki page is also maintained by the author himself, and everybody is encour
The code base is borrowed directly from the standard [[NginxHttpHeadersModule|headers]] module in Nginx 0.8.24. This part of code is copyrighted by Igor Sysoev.
-Copyright (c) 2009-2010, Taobao Inc., Alibaba Group ( http://www.taobao.com ).
+Copyright (c) 2009, 2010, 2011, Taobao Inc., Alibaba Group ( http://www.taobao.com ).
-Copyright (c) 2009-2010, agentzh <agentzh@gmail.com>.
+Copyright (c) 2009, 2010, 2011, Yichun "agentzh" Zhang (章亦春) <agentzh@gmail.com>.
-Copyright (c) 2010, Bernd Dorn.
+Copyright (c) 2010, 2011, Bernd Dorn.
This module is licensed under the terms of the BSD license.
@@ -368,7 +372,6 @@ are met:
* Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer.
* Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution.
-* Neither the name of the Taobao Inc. nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission.
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
@@ -384,9 +387,9 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
= See Also =
-* The original thread on the Nginx mailing list that inspires this module's development: [http://www.pubbs.net/nginx/200910/6361/ "A question about add_header replication"].
-* The orginal announcement thread on the Nginx mailing list: [http://www.pubbs.net/nginx/200911/29942/ "The "headers_more" module: Set and clear output headers...more than 'add'!"].
-* The original [http://agentzh.spaces.live.com/blog/cns!FF3A735632E41548!482.entry blog post] about this module's initial development.
+* The original thread on the Nginx mailing list that inspires this module's development: [http://forum.nginx.org/read.php?2,11206,11738 "A question about add_header replication"].
+* The orginal announcement thread on the Nginx mailing list: [http://forum.nginx.org/read.php?2,23460 "The "headers_more" module: Set and clear output headers...more than 'add'!"].
+* The original [http://agentzh.blogspot.com/2009/11/headers-more-module-scripting-input-and.html blog post] about this module's initial development.
* The [[NginxHttpEchoModule|echo module]] for Nginx module's automated testing.
* The standard [[NginxHttpHeadersModule|headers]] module.

0 comments on commit 2cbbc15

Please sign in to comment.