Changeset 2139:f6e578b1b02d in nginx_org


Ignore:
Timestamp:
04/09/18 08:52:48 (2 years ago)
Author:
Ruslan Ermilov <ru@…>
Branch:
default
Phase:
public
Message:

Updated docs for the upcoming NGINX Plus release.

Files:
1 added
12 edited

Legend:

Unmodified
Added
Removed
  • xml/en/GNUmakefile

    r2130 r2139  
    120120                stream/ngx_stream_upstream_module                       \
    121121                stream/ngx_stream_upstream_hc_module                    \
     122                stream/ngx_stream_zone_sync_module                      \
    122123                stream/stream_processing                                \
    123124                ngx_google_perftools_module                             \
  • xml/en/docs/http/ngx_http_api_module.xml

    r2133 r2139  
    102102Examples of API requests with this configuration:
    103103<example>
    104 http://127.0.0.1/api/2/
    105 http://127.0.0.1/api/2/nginx
    106 http://127.0.0.1/api/2/connections
    107 http://127.0.0.1/api/2/http/requests
    108 http://127.0.0.1/api/2/http/server_zones/server_backend
    109 http://127.0.0.1/api/2/http/caches/cache_backend
    110 http://127.0.0.1/api/2/http/upstreams/backend
    111 http://127.0.0.1/api/2/http/upstreams/backend/servers/
    112 http://127.0.0.1/api/2/http/upstreams/backend/servers/1
    113 http://127.0.0.1/api/2/http/keyvals/one?key=arg1
    114 http://127.0.0.1/api/2/stream/
    115 http://127.0.0.1/api/2/stream/server_zones/server_backend
    116 http://127.0.0.1/api/2/stream/upstreams/
    117 http://127.0.0.1/api/2/stream/upstreams/backend
    118 http://127.0.0.1/api/2/stream/upstreams/backend/servers/1
     104http://127.0.0.1/api/3/
     105http://127.0.0.1/api/3/nginx
     106http://127.0.0.1/api/3/connections
     107http://127.0.0.1/api/3/http/requests
     108http://127.0.0.1/api/3/http/server_zones/server_backend
     109http://127.0.0.1/api/3/http/caches/cache_backend
     110http://127.0.0.1/api/3/http/upstreams/backend
     111http://127.0.0.1/api/3/http/upstreams/backend/servers/
     112http://127.0.0.1/api/3/http/upstreams/backend/servers/1
     113http://127.0.0.1/api/3/http/keyvals/one?key=arg1
     114http://127.0.0.1/api/3/stream/
     115http://127.0.0.1/api/3/stream/server_zones/server_backend
     116http://127.0.0.1/api/3/stream/upstreams/
     117http://127.0.0.1/api/3/stream/upstreams/backend
     118http://127.0.0.1/api/3/stream/upstreams/backend/servers/1
    119119</example>
    120120</para>
     
    147147If the request URI equals the location prefix,
    148148the list of supported API versions is returned.
    149 The current API version is “<literal>2</literal>”.
     149The current API version is “<literal>3</literal>”.
    150150</para>
    151151
     
    154154specifies which fields of the requested objects will be output:
    155155<example>
    156 http://127.0.0.1/api/2/nginx?fields=version,build
     156http://127.0.0.1/api/3/nginx?fields=version,build
    157157</example>
    158158</para>
     
    166166<para>
    167167<list type="bullet">
     168
     169<listitem>
     170The <link id="stream_zone_sync_">/stream/zone_sync/</link> data
     171were added in <link id="api_version">version</link> 3.
     172</listitem>
    168173
    169174<listitem>
     
    14311436<link url="https://nginx.org/en/docs/stream/ngx_stream_core_module.html#stream">stream</link> not configured (<literal>StreamNotConfigured</literal>), returns <link id="def_nginx_error">Error</link></listitem>
    14321437<listitem>405 - Method disabled (<literal>MethodDisabled</literal>), returns <link id="def_nginx_error">Error</link></listitem>
     1438</list>
     1439</listitem>
     1440</list>
     1441</tag-desc>
     1442<tag-name id="stream_zone_sync_" name="/stream/zone_sync/">
     1443<literal>/stream/zone_sync/</literal>
     1444</tag-name>
     1445<tag-desc>
     1446<para>Supported methods:</para>
     1447<list type="bullet" compact="yes">
     1448<listitem id="getStreamZoneSync">
     1449<literal>GET</literal> - Return sync status of a node
     1450<para>Returns synchronization status of a cluster node.</para>
     1451<para>
     1452Possible responses:
     1453</para>
     1454<list type="bullet">
     1455<listitem>200 - Success, returns <link id="def_nginx_stream_zone_sync">Stream Zone Sync Node</link></listitem>
     1456<listitem>404 - Zone sync not configured (<literal>ZoneSyncNotConfigured</literal>),
     1457<link url="https://nginx.org/en/docs/stream/ngx_stream_core_module.html#stream">stream</link> not configured (<literal>StreamNotConfigured</literal>), returns <link id="def_nginx_error">Error</link></listitem>
    14331458</list>
    14341459</listitem>
     
    28792904}</example>
    28802905</listitem>
     2906<listitem id="def_nginx_stream_zone_sync">
     2907<para>Stream Zone Sync Node:</para>
     2908<list type="tag">
     2909<tag-name>
     2910<literal>zones</literal></tag-name>
     2911<tag-desc>
     2912<para>Synchronization information per each shared memory zone.</para><para>A collection of "<link id="def_nginx_stream_zone_sync_zone">Sync Zone</link>" objects</para>
     2913</tag-desc>
     2914<tag-name>
     2915<literal>status</literal></tag-name>
     2916<tag-desc>
     2917Synchronization information per node in a cluster.<list type="tag">
     2918<tag-name>
     2919<literal>bytes_in</literal> (<literal>integer</literal>)
     2920</tag-name>
     2921<tag-desc>
     2922The number of bytes received by this node.
     2923</tag-desc>
     2924<tag-name>
     2925<literal>msgs_in</literal> (<literal>integer</literal>)
     2926</tag-name>
     2927<tag-desc>
     2928The number of messages received by this node.
     2929</tag-desc>
     2930<tag-name>
     2931<literal>msgs_out</literal> (<literal>integer</literal>)
     2932</tag-name>
     2933<tag-desc>
     2934The number of messages sent by this node.
     2935</tag-desc>
     2936<tag-name>
     2937<literal>bytes_out</literal> (<literal>integer</literal>)
     2938</tag-name>
     2939<tag-desc>
     2940The number of bytes sent by this node.
     2941</tag-desc>
     2942<tag-name>
     2943<literal>nodes_online</literal> (<literal>integer</literal>)
     2944</tag-name>
     2945<tag-desc>
     2946The number of peers this node is connected to.
     2947</tag-desc>
     2948</list>
     2949</tag-desc>
     2950</list>
     2951<para>Example:</para>
     2952<example>
     2953{
     2954  "zones" : {
     2955    "zone1" : {
     2956      "records_pending" : 2061,
     2957      "records_total" : 260575
     2958    },
     2959    "zone2" : {
     2960      "records_pending" : 0,
     2961      "records_total" : 14749
     2962    }
     2963  },
     2964  "status" : {
     2965    "bytes_in" : 1364923761,
     2966    "msgs_in" : 337236,
     2967    "msgs_out" : 346717,
     2968    "bytes_out" : 1402765472,
     2969    "nodes_online" : 15
     2970  }
     2971}</example>
     2972</listitem>
     2973<listitem id="def_nginx_stream_zone_sync_zone">
     2974<para>Sync Zone:</para>
     2975Synchronization status of a shared memory zone.<list type="tag">
     2976<tag-name>
     2977<literal>records_pending</literal> (<literal>integer</literal>)
     2978</tag-name>
     2979<tag-desc>
     2980The number of records that need to be sent to the cluster.
     2981</tag-desc>
     2982<tag-name>
     2983<literal>records_total</literal> (<literal>integer</literal>)
     2984</tag-name>
     2985<tag-desc>
     2986The total number of records stored in the shared memory zone.
     2987</tag-desc>
     2988</list>
     2989</listitem>
    28812990<listitem id="def_nginx_error">
    28822991<para>Error:</para>
  • xml/en/docs/http/ngx_http_api_module_head.xml

    r2082 r2139  
    102102Examples of API requests with this configuration:
    103103<example>
    104 http://127.0.0.1/api/2/
    105 http://127.0.0.1/api/2/nginx
    106 http://127.0.0.1/api/2/connections
    107 http://127.0.0.1/api/2/http/requests
    108 http://127.0.0.1/api/2/http/server_zones/server_backend
    109 http://127.0.0.1/api/2/http/caches/cache_backend
    110 http://127.0.0.1/api/2/http/upstreams/backend
    111 http://127.0.0.1/api/2/http/upstreams/backend/servers/
    112 http://127.0.0.1/api/2/http/upstreams/backend/servers/1
    113 http://127.0.0.1/api/2/http/keyvals/one?key=arg1
    114 http://127.0.0.1/api/2/stream/
    115 http://127.0.0.1/api/2/stream/server_zones/server_backend
    116 http://127.0.0.1/api/2/stream/upstreams/
    117 http://127.0.0.1/api/2/stream/upstreams/backend
    118 http://127.0.0.1/api/2/stream/upstreams/backend/servers/1
     104http://127.0.0.1/api/3/
     105http://127.0.0.1/api/3/nginx
     106http://127.0.0.1/api/3/connections
     107http://127.0.0.1/api/3/http/requests
     108http://127.0.0.1/api/3/http/server_zones/server_backend
     109http://127.0.0.1/api/3/http/caches/cache_backend
     110http://127.0.0.1/api/3/http/upstreams/backend
     111http://127.0.0.1/api/3/http/upstreams/backend/servers/
     112http://127.0.0.1/api/3/http/upstreams/backend/servers/1
     113http://127.0.0.1/api/3/http/keyvals/one?key=arg1
     114http://127.0.0.1/api/3/stream/
     115http://127.0.0.1/api/3/stream/server_zones/server_backend
     116http://127.0.0.1/api/3/stream/upstreams/
     117http://127.0.0.1/api/3/stream/upstreams/backend
     118http://127.0.0.1/api/3/stream/upstreams/backend/servers/1
    119119</example>
    120120</para>
     
    147147If the request URI equals the location prefix,
    148148the list of supported API versions is returned.
    149 The current API version is “<literal>2</literal>”.
     149The current API version is “<literal>3</literal>”.
    150150</para>
    151151
     
    154154specifies which fields of the requested objects will be output:
    155155<example>
    156 http://127.0.0.1/api/2/nginx?fields=version,build
     156http://127.0.0.1/api/3/nginx?fields=version,build
    157157</example>
    158158</para>
     
    166166<para>
    167167<list type="bullet">
     168
     169<listitem>
     170The <link id="stream_zone_sync_">/stream/zone_sync/</link> data
     171were added in <link id="api_version">version</link> 3.
     172</listitem>
    168173
    169174<listitem>
  • xml/en/docs/http/ngx_http_auth_jwt_module.xml

    r2086 r2139  
    1010        link="/en/docs/http/ngx_http_auth_jwt_module.html"
    1111        lang="en"
    12         rev="5">
     12        rev="6">
    1313
    1414<section id="summary">
     
    9696<context>server</context>
    9797<context>location</context>
     98<context>limit_except</context>
    9899
    99100<para>
     
    156157For arrays, the variable keeps a list of array elements separated by commas.
    157158<example>
    158 auth_jwt_claim_set $email info e-mail;
    159 auth_jwt_claim_set $job info "job title";
     159location / {
     160    auth_jwt           "closed site";
     161    auth_jwt_key_file  conf/keys.json;
     162    auth_jwt_claim_set $email info e-mail;
     163    auth_jwt_claim_set $job info "job title";
     164}
    160165</example>
    161166<note>
     
    168173
    169174
     175<directive name="auth_jwt_leeway">
     176<syntax><value>time</value></syntax>
     177<default>0s</default>
     178<context>http</context>
     179<context>server</context>
     180<context>location</context>
     181<appeared-in>1.13.11</appeared-in>
     182
     183<para>
     184Sets the maximum allowable leeway to compensate
     185clock skew when verifying the
     186<link url="https://tools.ietf.org/html/rfc7519#section-4.1.4">exp</link>
     187and
     188<link url="https://tools.ietf.org/html/rfc7519#section-4.1.5">nbf</link>
     189JWT claims.
     190</para>
     191
     192</directive>
     193
     194
    170195<directive name="auth_jwt_key_file">
    171196<syntax><value>file</value></syntax>
     
    174199<context>server</context>
    175200<context>location</context>
     201<context>limit_except</context>
    176202
    177203<para>
  • xml/en/docs/http/ngx_http_core_module.xml

    r2134 r2139  
    1111        link="/en/docs/http/ngx_http_core_module.html"
    1212        lang="en"
    13         rev="77">
     13        rev="78">
    1414
    1515<section id="directives" name="Directives">
     
    10061006<literal>HEAD</literal> method also allowed.
    10071007Access to other methods can be limited using the
    1008 <link doc="ngx_http_access_module.xml">ngx_http_access_module</link>
     1008<link doc="ngx_http_access_module.xml">ngx_http_access_module</link>,
     1009<link doc="ngx_http_auth_basic_module.xml">ngx_http_auth_basic_module</link>,
    10091010and
    1010 <link doc="ngx_http_auth_basic_module.xml">ngx_http_auth_basic_module</link>
     1011<link doc="ngx_http_auth_jwt_module.xml">ngx_http_auth_jwt_module</link>
     1012(1.13.10)
    10111013modules directives:
    10121014<example>
  • xml/en/docs/http/ngx_http_upstream_module.xml

    r2134 r2139  
    1111        link="/en/docs/http/ngx_http_upstream_module.html"
    1212        lang="en"
    13         rev="69">
     13        rev="70">
    1414
    1515<section id="summary">
     
    821821    <literal>zone=</literal><value>name</value>:<value>size</value>
    822822    [<literal>timeout=</literal><value>time</value>]
    823     [<literal>header</literal>]</syntax>
     823    [<literal>header</literal>]
     824    [<literal>sync</literal>]</syntax>
    824825<default/>
    825826<context>upstream</context>
     
    10011002Sessions are stored in a shared memory zone, whose <value>name</value> and
    10021003<value>size</value> are configured by the <literal>zone</literal> parameter.
    1003 One megabyte zone can store about 8000 sessions on the 64-bit platform.
     1004One megabyte zone can store about 4000 sessions on the 64-bit platform.
    10041005The sessions that are not accessed during the time specified by the
    10051006<literal>timeout</literal> parameter get removed from the zone.
     
    10101011The <literal>header</literal> parameter (1.13.1) allows creating a session
    10111012right after receiving response headers from the upstream server.
     1013</para>
     1014
     1015<para id="sticky_learn_sync">
     1016The <literal>sync</literal> parameter (1.13.8) enables
     1017<link doc="../stream/ngx_stream_zone_sync_module.xml" id="zone_sync">synchronization</link>
     1018of the shared memory zone.
    10121019</para>
    10131020
     
    11341141</tag-desc>
    11351142
     1143<tag-name id="var_upstream_queue_time"><var>$upstream_queue_time</var></tag-name>
     1144<tag-desc>
     1145keeps time the request spent in the upstream <link id="queue">queue</link>
     1146(1.13.9);
     1147the time is kept in seconds with millisecond resolution.
     1148Times of several responses
     1149are separated by commas and colons like addresses in the
     1150<link id="var_upstream_addr">$upstream_addr</link> variable.
     1151</tag-desc>
     1152
    11361153<tag-name id="var_upstream_response_length"><var>$upstream_response_length</var>
    11371154</tag-name>
  • xml/en/docs/index.xml

    r2114 r2139  
    99         link="/en/docs/"
    1010         lang="en"
    11          rev="44"
     11         rev="45"
    1212         toc="no">
    1313
     
    622622</listitem>
    623623
     624<listitem>
     625<link doc="stream/ngx_stream_zone_sync_module.xml">
     626ngx_stream_zone_sync_module</link>
     627</listitem>
     628
    624629</list>
    625630</para>
  • xml/ru/docs/http/ngx_http_auth_jwt_module.xml

    r2086 r2139  
    1010        link="/ru/docs/http/ngx_http_auth_jwt_module.html"
    1111        lang="ru"
    12         rev="5">
     12        rev="6">
    1313
    1414<section id="summary">
     
    9494<context>server</context>
    9595<context>location</context>
     96<context>limit_except</context>
    9697
    9798<para>
     
    154155Для массива переменная хранит список его элементов, разделяемых запятыми.
    155156<example>
    156 auth_jwt_claim_set $email info e-mail;
    157 auth_jwt_claim_set $job info "job title";
     157location / {
     158    auth_jwt           "closed site";
     159    auth_jwt_key_file  conf/keys.json;
     160    auth_jwt_claim_set $email info e-mail;
     161    auth_jwt_claim_set $job info "job title";
     162}
    158163</example>
    159164<note>
     
    166171
    167172
     173<directive name="auth_jwt_leeway">
     174<syntax><value>время</value></syntax>
     175<default>0s</default>
     176<context>http</context>
     177<context>server</context>
     178<context>location</context>
     179<appeared-in>1.13.11</appeared-in>
     180
     181<para>
     182Задаёт максимально допустимое отклонение времени для компенсации
     183расхождения часов при проверке JWT claims
     184<link url="https://tools.ietf.org/html/rfc7519#section-4.1.4">exp</link>
     185и
     186<link url="https://tools.ietf.org/html/rfc7519#section-4.1.5">nbf</link>.
     187</para>
     188
     189</directive>
     190
     191
    168192<directive name="auth_jwt_key_file">
    169193<syntax><value>файл</value></syntax>
     
    172196<context>server</context>
    173197<context>location</context>
     198<context>limit_except</context>
    174199
    175200<para>
  • xml/ru/docs/http/ngx_http_core_module.xml

    r2134 r2139  
    1111        link="/ru/docs/http/ngx_http_core_module.html"
    1212        lang="ru"
    13         rev="77">
     13        rev="78">
    1414
    1515<section id="directives" name="Директивы">
     
    10031003<literal>HEAD</literal> также будет разрешён.
    10041004Доступ к остальным методам может быть ограничен при помощи директив модулей
    1005 <link doc="ngx_http_access_module.xml">ngx_http_access_module</link>
     1005<link doc="ngx_http_access_module.xml">ngx_http_access_module</link>,
     1006<link doc="ngx_http_auth_basic_module.xml">ngx_http_auth_basic_module</link>
    10061007и
    1007 <link doc="ngx_http_auth_basic_module.xml">ngx_http_auth_basic_module</link>:
     1008<link doc="ngx_http_auth_jwt_module.xml">ngx_http_auth_jwt_module</link>
     1009(1.13.10):
    10081010<example>
    10091011limit_except GET {
  • xml/ru/docs/http/ngx_http_upstream_module.xml

    r2134 r2139  
    1111        link="/ru/docs/http/ngx_http_upstream_module.html"
    1212        lang="ru"
    13         rev="69">
     13        rev="70">
    1414
    1515<section id="summary">
     
    828828    <literal>zone=</literal><value>имя</value>:<value>размер</value>
    829829    [<literal>timeout=</literal><value>время</value>]
    830     [<literal>header</literal>]</syntax>
     830    [<literal>header</literal>]
     831    [<literal>sync</literal>]</syntax>
    831832<default/>
    832833<context>upstream</context>
     
    10051006Сессии хранятся в зоне разделяемой памяти, <value>имя</value> и
    10061007<value>размер</value> которой задаются параметром <literal>zone</literal>.
    1007 Зоны размером в 1 мегабайт достаточно для хранения около 8 тысяч сессий
     1008Зоны размером в 1 мегабайт достаточно для хранения около 4 тысяч сессий
    10081009на 64-битной платформе.
    10091010Сессии, к которым не было обращений в течение времени, заданного параметром
     
    10151016Параметр <literal>header</literal> (1.13.1) позволяет создавать сессию
    10161017сразу после получения заголовков ответа от сервера группы.
     1018</para>
     1019
     1020<para id="sticky_learn_sync">
     1021Параметр <literal>sync</literal> (1.13.8) разрешает
     1022<link doc="../stream/ngx_stream_zone_sync_module.xml" id="zone_sync">синхронизацию</link>
     1023данной зоны разделяемой памяти.
    10171024</para>
    10181025
     
    11411148</tag-desc>
    11421149
     1150<tag-name id="var_upstream_queue_time"><var>$upstream_queue_time</var></tag-name>
     1151<tag-desc>
     1152хранит время, проведённое запросом в <link id="queue">очереди</link>
     1153(1.13.9);
     1154время хранится в секундах с точностью до миллисекунд.
     1155Времена нескольких ответов
     1156разделяются запятыми и двоеточиями подобно адресам в переменной
     1157<link id="var_upstream_addr">$upstream_addr</link>.
     1158</tag-desc>
     1159
    11431160<tag-name id="var_upstream_response_length"><var>$upstream_response_length</var>
    11441161</tag-name>
  • xml/ru/docs/index.xml

    r2114 r2139  
    99         link="/ru/docs/"
    1010         lang="ru"
    11          rev="44"
     11         rev="45"
    1212         toc="no">
    1313
     
    627627</listitem>
    628628
     629<listitem>
     630<link doc="stream/ngx_stream_zone_sync_module.xml">
     631ngx_stream_zone_sync_module</link> [en]
     632</listitem>
     633
    629634</list>
    630635</para>
  • yaml/nginx_api.yaml

    r2133 r2139  
    1010    [http](https://nginx.org/en/docs/http/ngx_http_keyval_module.html) and
    1111    [stream](https://nginx.org/en/docs/stream/ngx_stream_keyval_module.html).
    12 basePath: /api/2
     12basePath: /api/3
    1313tags:
    1414  - name: General Info
     
    2727  - name: Stream Upstreams
    2828  - name: Stream Keyvals
     29  - name: Stream Zone Sync
    2930  - name: Method GET
    3031  - name: Method POST
     
    14751476        '405':
    14761477          description: Method disabled (*MethodDisabled*)
     1478          schema:
     1479            $ref: '#/definitions/NginxError'
     1480  /stream/zone_sync/:
     1481    get:
     1482      tags:
     1483        - Stream Zone Sync
     1484        - Method GET
     1485      summary: Return sync status of a node
     1486      description: Returns synchronization status of a cluster node.
     1487      operationId: getStreamZoneSync
     1488      produces:
     1489        - application/json
     1490      responses:
     1491        '200':
     1492          description: Success
     1493          schema:
     1494            $ref: '#/definitions/NginxStreamZoneSync'
     1495        '404':
     1496          description: |
     1497            Zone sync not configured (*ZoneSyncNotConfigured*),
     1498            [stream](https://nginx.org/en/docs/stream/ngx_stream_core_module.html#stream) not configured (*StreamNotConfigured*)
    14771499          schema:
    14781500            $ref: '#/definitions/NginxError'
     
    31413163      key2: value2
    31423164      key3: value3
     3165  NginxStreamZoneSync:
     3166    title: Stream Zone Sync Node
     3167    type: object
     3168    properties:
     3169      zones:
     3170        type: object
     3171        title: Zone Sync Zones
     3172        description: Synchronization information per each shared memory zone.
     3173        additionalProperties:
     3174          $ref: '#/definitions/NginxStreamZoneSyncZone'
     3175      status:
     3176        type: object
     3177        description: Synchronization information per node in a cluster.
     3178        properties:
     3179          bytes_in:
     3180            type: integer
     3181            description: The number of bytes received by this node.
     3182          msgs_in:
     3183            type: integer
     3184            description: The number of messages received by this node.
     3185          msgs_out:
     3186            type: integer
     3187            description: The number of messages sent by this node.
     3188          bytes_out:
     3189            type: integer
     3190            description: The number of bytes sent by this node.
     3191          nodes_online:
     3192            type: integer
     3193            description: The number of peers this node is connected to.
     3194    example:
     3195      zones:
     3196        zone1:
     3197          records_pending: 2061
     3198          records_total: 260575
     3199        zone2:
     3200          records_pending: 0
     3201          records_total: 14749
     3202      status:
     3203        bytes_in: 1364923761
     3204        msgs_in: 337236
     3205        msgs_out: 346717
     3206        bytes_out: 1402765472
     3207        nodes_online: 15
     3208  NginxStreamZoneSyncZone:
     3209    title: Sync Zone
     3210    description: Synchronization status of a shared memory zone.
     3211    type: object
     3212    properties:
     3213      records_pending:
     3214        type: integer
     3215        description: The number of records that need to be sent to the cluster.
     3216      records_total:
     3217        type: integer
     3218        description: The total number of records stored in the shared memory zone.
    31433219  NginxError:
    31443220    title: Error
Note: See TracChangeset for help on using the changeset viewer.