comparison xml/en/docs/stream/ngx_stream_js_module.xml @ 2128:59a3cc84f507

Renamed nginScript to njs
author Yaroslav Zhuravlev <yar@nginx.com>
date Tue, 03 Apr 2018 20:23:40 +0300
parents af51ec6b5489
children 6c7841469ec5
comparison
equal deleted inserted replaced
2127:284598bb7fbb 2128:59a3cc84f507
7 <!DOCTYPE module SYSTEM "../../../../dtd/module.dtd"> 7 <!DOCTYPE module SYSTEM "../../../../dtd/module.dtd">
8 8
9 <module name="Module ngx_stream_js_module" 9 <module name="Module ngx_stream_js_module"
10 link="/en/docs/stream/ngx_stream_js_module.html" 10 link="/en/docs/stream/ngx_stream_js_module.html"
11 lang="en" 11 lang="en"
12 rev="8"> 12 rev="9">
13 13
14 <section id="summary"> 14 <section id="summary">
15 15
16 <para> 16 <para>
17 The <literal>ngx_stream_js_module</literal> module is used to implement 17 The <literal>ngx_stream_js_module</literal> module is used to implement
18 handlers in <link doc="../njs_about.xml">nginScript</link> — 18 handlers in <link doc="../njs_about.xml">njs</link> —
19 a subset of the JavaScript language. 19 a subset of the JavaScript language.
20 </para> 20 </para>
21 21
22 <para> 22 <para>
23 This module is not built by default, it should be compiled with 23 This module is not built by default, it should be compiled with
24 the nginScript module using the 24 the njs module using the
25 <literal>--add-module</literal> configuration parameter: 25 <literal>--add-module</literal> configuration parameter:
26 <example> 26 <example>
27 ./configure --add-module=<value>path-to-njs</value>/nginx 27 ./configure --add-module=<value>path-to-njs</value>/nginx
28 </example> 28 </example>
29 The <link url="http://hg.nginx.org/njs">repository</link> 29 The <link url="http://hg.nginx.org/njs">repository</link>
30 with the nginScript module can be cloned with the following command 30 with the njs module can be cloned with the following command
31 (requires <link url="https://www.mercurial-scm.org">Mercurial</link> client): 31 (requires <link url="https://www.mercurial-scm.org">Mercurial</link> client):
32 <example> 32 <example>
33 hg clone http://hg.nginx.org/njs 33 hg clone http://hg.nginx.org/njs
34 </example> 34 </example>
35 This module can also be built as 35 This module can also be built as
166 <default/> 166 <default/>
167 <context>stream</context> 167 <context>stream</context>
168 <context>server</context> 168 <context>server</context>
169 169
170 <para> 170 <para>
171 Sets an nginScript function which will be called at the 171 Sets an njs function which will be called at the
172 <link doc="stream_processing.xml" id="access_phase">access</link> phase. 172 <link doc="stream_processing.xml" id="access_phase">access</link> phase.
173 </para> 173 </para>
174 174
175 </directive> 175 </directive>
176 176
192 <syntax><value>file</value></syntax> 192 <syntax><value>file</value></syntax>
193 <default/> 193 <default/>
194 <context>stream</context> 194 <context>stream</context>
195 195
196 <para> 196 <para>
197 Specifies a file that implements server and variable handlers in nginScript. 197 Specifies a file that implements server and variable handlers in njs.
198 </para> 198 </para>
199 199
200 </directive> 200 </directive>
201 201
202 202
205 <default/> 205 <default/>
206 <context>stream</context> 206 <context>stream</context>
207 <context>server</context> 207 <context>server</context>
208 208
209 <para> 209 <para>
210 Sets an nginScript function which will be called at the 210 Sets an njs function which will be called at the
211 <link doc="stream_processing.xml" id="preread_phase">preread</link> phase. 211 <link doc="stream_processing.xml" id="preread_phase">preread</link> phase.
212 </para> 212 </para>
213 213
214 </directive> 214 </directive>
215 215
219 <value>$variable</value> <value>function</value></syntax> 219 <value>$variable</value> <value>function</value></syntax>
220 <default/> 220 <default/>
221 <context>stream</context> 221 <context>stream</context>
222 222
223 <para> 223 <para>
224 Sets an nginScript function for the specified variable. 224 Sets an njs function for the specified variable.
225 </para> 225 </para>
226 226
227 </directive> 227 </directive>
228 228
229 </section> 229 </section>
230 230
231 231
232 <section id="properties" name="Session Object Properties"> 232 <section id="properties" name="Session Object Properties">
233 <para> 233 <para>
234 Each stream nginScript handler receives one argument, a stream session object. 234 Each stream njs handler receives one argument, a stream session object.
235 </para> 235 </para>
236 236
237 <para> 237 <para>
238 The session object has the following properties: 238 The session object has the following properties:
239 239