# Working on Nginx Tutorials in Chinese

**URL:** <https://www.ruby-forum.com/t/working-on-nginx-tutorials-in-chinese/214576>\
**Category:** NGINX\
**Created:** [December 6, 2011, 8:56am UTC](https://www.ruby-forum.com/t/working-on-nginx-tutorials-in-chinese/214576 "2011-12-06T08:56:59Z")\
**Posts on this page:** 10\
**Page:** 1

<div class="post-metadata">

**Author:** ![dubstep](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/d/cdc98d/32.png) [@dubstep](https://www.ruby-forum.com/u/dubstep)\
**Post date:** [December 6, 2011, 8:56am UTC](https://www.ruby-forum.com/t/working-on-nginx-tutorials-in-chinese/214576/1 "2011-12-06T08:56:59Z")

</div>

Hi, folks!

I’ve been posting Nginx tutorials in Chinese to my yet another blog  
site hosted by Sina Blog here:

[agentzh\_新浪博客](http://blog.sina.com.cn/openresty)

I’m currently posting tutorials for the “Nginx Variables” series in  
great details. And I’m trying to post an article every work day.

I’m hoping that I can eventually work out an Nginx book in Chinese  
based on these materials soon so I’m working hard and seriously.

If you cannot read Chinese, please try out translating tools like  
Google Translator 😉 I’m very willing to find someone to translate  
these to English or any other languages though 🙂

Enjoy!  
-agentzh

---

<div class="post-metadata">

**Author:** ![agentzh](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/a/4da419/32.png) [@agentzh](https://www.ruby-forum.com/u/agentzh)\
**Post date:** [December 6, 2011, 9:21am UTC](https://www.ruby-forum.com/t/working-on-nginx-tutorials-in-chinese/214576/2 "2011-12-06T09:21:08Z")

</div>

在 2011-12-06二的 15:56 +0800，agentzh写道：

> I’m hoping that I can eventually work out an Nginx book in Chinese  
> nginx mailing list  
> [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid)  
> [mailman.nginx.org archive](http://mailman.nginx.org/mailman/listinfo/nginx)

i think you should leave any 3rd BSP such as Sina,Netease.and build your  
own weblog platform(why not use Nginx + Wordpress),and put those content  
on it.

just a suggestion.

–  
Best regards,  
Sharl.Jimh.Tsin (From China **Obviously Taiwan INCLUDED** )

Using Gmail? Please read this important notice:  
[Gmail — Free Software Foundation — Working together for free software](http://www.fsf.org/campaigns/jstrap/gmail?10073).

---

<div class="post-metadata">

**Author:** ![agentzh](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/a/4da419/32.png) [@agentzh](https://www.ruby-forum.com/u/agentzh)\
**Post date:** [December 6, 2011, 10:26am UTC](https://www.ruby-forum.com/t/working-on-nginx-tutorials-in-chinese/214576/3 "2011-12-06T10:26:09Z")

</div>

On 6 Dez 2011 07h56 WET, [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid) wrote:

> Hi, folks!
> 
> I’ve been posting Nginx tutorials in Chinese to my yet another blog  
> site hosted by Sina Blog here:
> 
> [http://blog.sina.com.cn/openresty](http://blog.sina.com.cn/openresty)

Hello agentzh,

I’ve riped out the http\_concat\_module from tengine and compiled it  
against 1.1.10 as a regular HTTP (not filter) module.

I enabled the debug level on the error log and strangely (or not)  
enough I never watch signs of life from the module.

With:

concat on; # default off  
concat\_max\_files 20; # default 10

on a CSS/JS providing location.

I’ve played with the concat\_unique flag also.

From my very poor understanding the code does the following.

It tries to concatenate requests of CSS/JS files (the default types)  
as a single one whenever the client requests several of these  
resources on a given location.

It uses the OS file cache whenever possible.

Since we’re not changing the page, the client request made are the  
same the concat module does all this stuff “in request handling”.

Am I at least partially correct?

Thank you,  
— appa

---

<div class="post-metadata">

**Author:** ![agentzh](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/a/4da419/32.png) [@agentzh](https://www.ruby-forum.com/u/agentzh)\
**Post date:** [December 6, 2011, 10:41am UTC](https://www.ruby-forum.com/t/working-on-nginx-tutorials-in-chinese/214576/4 "2011-12-06T10:41:03Z")

</div>

On Tue, Dec 6, 2011 at 5:24 PM, Antnio P. P. Almeida [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid)  
wrote:

> Hello agentzh,
> 
> I’ve riped out the http\_concat\_module from tengine and compiled it  
> against 1.1.10 as a regular HTTP (not filter) module.

Please do not reply to a mailing list thread with contents totally  
unrelated because this is confusing.

Also, I’m not the maintainer of Tengine nor its concat module and thus  
not qualified to answer any of your questions. Sorry.

Maybe Joshua Z. can answer that for you? Already cc’d 🙂

Best,  
-agentzh

---

<div class="post-metadata">

**Author:** ![agentzh](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/a/4da419/32.png) [@agentzh](https://www.ruby-forum.com/u/agentzh)\
**Post date:** [December 6, 2011, 10:52am UTC](https://www.ruby-forum.com/t/working-on-nginx-tutorials-in-chinese/214576/5 "2011-12-06T10:52:51Z")

</div>

On 6 Dez 2011 09h40 WET, [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid) wrote:

> On Tue, Dec 6, 2011 at 5:24 PM, António P. P. Almeida  
> [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid) wrote:
> 
> > Hello agentzh,
> > 
> > I’ve riped out the http\_concat\_module from tengine and compiled it  
> > against 1.1.10 as a regular HTTP (not filter) module.
> 
> Please do not reply to a mailing list thread with contents totally  
> unrelated because this is confusing.

Yes, you’re right. I apologize.

> Also, I’m not the maintainer of Tengine nor its concat module and  
> thus not qualified to answer any of your questions. Sorry.

I erroneously thought that you were somehow involved, since AFAIK  
you’re working on the same chinese company.

> Maybe Joshua Z. can answer that for you? Already cc’d 🙂

Thank you,

— appa

---

<div class="post-metadata">

**Author:** ![agentzh](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/a/4da419/32.png) [@agentzh](https://www.ruby-forum.com/u/agentzh)\
**Post date:** [December 6, 2011, 10:44am UTC](https://www.ruby-forum.com/t/working-on-nginx-tutorials-in-chinese/214576/6 "2011-12-06T10:44:48Z")

</div>

On Tue, Dec 6, 2011 at 4:20 PM, Sharl.Jimh.Tsin [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid)  
wrote:

> i think you should leave any 3rd BSP such as Sina,Netease.and build your  
> own weblog platform(why not use Nginx + Wordpress),and put those content  
> on it.

I’ve been putting stuffs on Sina Blog just because I was too lazy to  
set up a blog myself and I’m always unwilling to run any online code  
written in any of those P\* languages in my own box 😉

> just a suggestion.

Thank you for your suggestion anyway 🙂

Best,  
-agentzh

---

<div class="post-metadata">

**Author:** ![agentzh](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/a/4da419/32.png) [@agentzh](https://www.ruby-forum.com/u/agentzh)\
**Post date:** [December 9, 2011, 4:37pm UTC](https://www.ruby-forum.com/t/working-on-nginx-tutorials-in-chinese/214576/7 "2011-12-09T16:37:40Z")

</div>

On 7 Dez 2011 03h16 WET, [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid) wrote:

> ```
> # (default on)
> 
> ```
> 
> Davis. Then mod\_concat was implemented by Ian Holsman at  
> [http://foobar.com/](http://foobar.com/)??a.js,b.js,c.js  
> [http://foobar.com/](http://foobar.com/)??a.css,b.css,c.css  
> [http://foobar.com/](http://foobar.com/)??a.js,dir1/b.js,dir2/c.js  
> [http://foobar.com/somelocation/](http://foobar.com/somelocation/)??1.js,2.js  
> [http://foobar.com/](http://foobar.com/)??a.js,b.js,c.js?t=20100520
> 
> SEE ALSO  
> [Google Code Archive - Long-term storage for Google Code Project Hosting.](http://code.google.com/p/modconcat/)  
> [http://www.artzstudio.com/2008/08/using-modconcat-to-speed-up-render-start/](http://www.artzstudio.com/2008/08/using-modconcat-to-speed-up-render-start/)

Thank you very much. I’ve placed the module on github with the proper  
attribution. Feel free to suggest any improvements to the README.

Regards,  
António

---

<div class="post-metadata">

**Author:** ![agentzh](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/a/4da419/32.png) [@agentzh](https://www.ruby-forum.com/u/agentzh)\
**Post date:** [December 9, 2011, 4:38pm UTC](https://www.ruby-forum.com/t/working-on-nginx-tutorials-in-chinese/214576/8 "2011-12-09T16:38:56Z")

</div>

On 7 Dez 2011 03h16 WET, removed\_email\_address@domain.invalid wrote:

Oops the URL was missing 🙂

> **[GitHub - perusio/nginx-http-concat: A Nginx module for concatenating files in...](https://github.com/perusio/nginx-http-concat)**
>
> A Nginx module for concatenating files in a given context: CSS and JS files usually - GitHub - perusio/nginx-http-concat: A Nginx module for concatenating files in a given context: CSS and JS file...

— appa

---

<div class="post-metadata">

**Author:** ![agentzh](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/a/4da419/32.png) [@agentzh](https://www.ruby-forum.com/u/agentzh)\
**Post date:** [December 7, 2011, 4:16am UTC](https://www.ruby-forum.com/t/working-on-nginx-tutorials-in-chinese/214576/9 "2011-12-07T04:16:33Z")

</div>

Hi,

On Tue, Dec 6, 2011 at 5:24 PM, Antnio P. P. Almeida  
[removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid)wrote:

> I’ve riped out the http\_concat\_module from tengine and compiled it  
> against 1.1.10 as a regular HTTP (not filter) module.

Thanks for agentzh’s CC.

Here is a synopsis below:

SYNOPSIS  
location /foo/ {  
# turn on concatenation  
# (default: off)  
concat on;  
}

location /bar/ {  
# turn on concatenation  
# (default: off)  
concat on;

```
 # max concat file number allowed
 # (default: 10)
 # concat_max_files 10;

 # only files in the same content types are allowed
 # (default on)
 # concat_unique on;

 # content types allowed
 # (default: application/x-javascript, text/css)
 # concat_types text/html;

```

}

DESCRIPTION  
The idea of combining multiple files together to speed up page  
rendering was first brought in perlbal, by David Davis. Then  
mod\_concat  
was implemented by Ian Holsman at AOL. This technique is really  
simple  
but very useful, by specifing a set of files to load in one HTTP  
request.

This module basically works as what its apache cousin does.  
Additionally, it also support maximum concat file number setting and  
version string (the string after the third question mark will be  
treated as version string and ignored).

EXAMPLE  
[http://foobar.com/](http://foobar.com/)??a.js,b.js,c.js  
[http://foobar.com/](http://foobar.com/)??a.css,b.css,c.css  
[http://foobar.com/](http://foobar.com/)??a.js,dir1/b.js,dir2/c.js  
[http://foobar.com/somelocation/](http://foobar.com/somelocation/)??1.js,2.js  
[http://foobar.com/](http://foobar.com/)??a.js,b.js,c.js?t=20100520

SEE ALSO  
[Google Code Archive - Long-term storage for Google Code Project Hosting.](http://code.google.com/p/modconcat/)  
[http://www.artzstudio.com/2008/08/using-modconcat-to-speed-up-render-start/](http://www.artzstudio.com/2008/08/using-modconcat-to-speed-up-render-start/)

Regards,

---

<div class="post-metadata">

**Author:** ![agentzh](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/a/4da419/32.png) [@agentzh](https://www.ruby-forum.com/u/agentzh)\
**Post date:** [December 9, 2011, 6:19pm UTC](https://www.ruby-forum.com/t/working-on-nginx-tutorials-in-chinese/214576/10 "2011-12-09T18:19:53Z")

</div>

Hi,

On Fri, Dec 9, 2011 at 11:36 PM, Antnio P. P. Almeida  
[removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid)wrote:

> On 7 Dez 2011 03h16 WET, [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid) wrote:
> 
> Oops the URL was missing 🙂
> 
> [GitHub - perusio/nginx-http-concat: A Nginx module for concatenating files in a given context: CSS and JS files usually · GitHub](https://github.com/perusio/nginx-http-concat)

Wow, cool!  
Thank you very much.

Regards,
