|
4978 | 4978 | "<p><code>zone</code>=<em><code>name</code></em>:<em><code>size</code></em> [<code>timeout</code>=<em><code>time</code></em>] [<code>type</code>=<code>string</code>|<code>number</code>] [<code>evict</code>]</p>\n"
|
4979 | 4979 | ],
|
4980 | 4980 | "isBlock": false,
|
4981 |
| - "description_md": "Sets the *`name`* and *`size`* of the shared memory zone\nthat keeps the\nkey-value [dictionary](https://nginx.org/en/docs/njs/reference.html#dict)\nshared between worker processes.\n\nBy default the shared dictionary uses a string as a key and a value.\nThe optional `type` parameter\nallows redefining the value type to number.\n\nThe optional `timeout` parameter sets\nthe time after which all shared dictionary entries are removed from the zone.\n\nThe optional `evict` parameter removes the oldest\nkey-value pair when the zone storage is exhausted.\n\nExample:\n```\nexample.conf:\n # Creates a 1Mb dictionary with string values,\n # removes key-value pairs after 60 seconds of inactivity:\n js_shared_dict_zone zone=foo:1M timeout=60s;\n\n # Creates a 512Kb dictionary with string values,\n # forcibly removes oldest key-value pairs when the zone is exhausted:\n js_shared_dict_zone zone=bar:512K timeout=30s evict;\n\n # Creates a 32Kb permanent dictionary with number values:\n js_shared_dict_zone zone=num:32k type=number;\n\nexample.js:\n function get(r) {\n r.return(200, ngx.shared.foo.get(r.args.key));\n }\n\n function set(r) {\n r.return(200, ngx.shared.foo.set(r.args.key, r.args.value));\n }\n\n function del(r) {\n r.return(200, ngx.shared.bar.delete(r.args.key));\n }\n\n function increment(r) {\n r.return(200, ngx.shared.num.incr(r.args.key, 2));\n }\n```", |
4982 |
| - "description_html": "<p>Sets the <em><code>name</code></em> and <em><code>size</code></em> of the shared memory zone\nthat keeps the\nkey-value <a href=\"https://nginx.org/en/docs/njs/reference.html#dict\" target=\"_blank\">dictionary</a>\nshared between worker processes.</p>\n\n<p>By default the shared dictionary uses a string as a key and a value.\nThe optional <code>type</code> parameter\nallows redefining the value type to number.</p>\n\n<p>The optional <code>timeout</code> parameter sets\nthe time after which all shared dictionary entries are removed from the zone.</p>\n\n<p>The optional <code>evict</code> parameter removes the oldest\nkey-value pair when the zone storage is exhausted.</p>\n\n<p>Example:</p>\n\n<pre><code>example.conf:\n # Creates a 1Mb dictionary with string values,\n # removes key-value pairs after 60 seconds of inactivity:\n js_shared_dict_zone zone=foo:1M timeout=60s;\n\n # Creates a 512Kb dictionary with string values,\n # forcibly removes oldest key-value pairs when the zone is exhausted:\n js_shared_dict_zone zone=bar:512K timeout=30s evict;\n\n # Creates a 32Kb permanent dictionary with number values:\n js_shared_dict_zone zone=num:32k type=number;\n\nexample.js:\n function get(r) {\n r.return(200, ngx.shared.foo.get(r.args.key));\n }\n\n function set(r) {\n r.return(200, ngx.shared.foo.set(r.args.key, r.args.value));\n }\n\n function del(r) {\n r.return(200, ngx.shared.bar.delete(r.args.key));\n }\n\n function increment(r) {\n r.return(200, ngx.shared.num.incr(r.args.key, 2));\n }\n</code></pre>\n" |
| 4981 | + "description_md": "Sets the *`name`* and *`size`* of the shared memory zone\nthat keeps the\nkey-value [dictionary](https://nginx.org/en/docs/njs/reference.html#dict)\nshared between worker processes.\n\nBy default the shared dictionary uses a string as a key and a value.\nThe optional `type` parameter\nallows redefining the value type to number.\n\nThe optional `timeout` parameter sets\nthe time in milliseconds\nafter which all shared dictionary entries are removed from the zone.\nIf some entries require a different removal time, it can be set\nwith the `timeout` argument of the\n[add](https://nginx.org/en/docs/njs/reference.html#dict_add),\n[incr](https://nginx.org/en/docs/njs/reference.html#dict_incr), and\n[set](https://nginx.org/en/docs/njs/reference.html#dict_set)\nmethods\n([0.8.5](https://nginx.org/en/docs/njs/changes.html#njs0.8.5)).\n\nThe optional `evict` parameter removes the oldest\nkey-value pair when the zone storage is exhausted.\n\nExample:\n```\nexample.conf:\n # Creates a 1Mb dictionary with string values,\n # removes key-value pairs after 60 seconds of inactivity:\n js_shared_dict_zone zone=foo:1M timeout=60s;\n\n # Creates a 512Kb dictionary with string values,\n # forcibly removes oldest key-value pairs when the zone is exhausted:\n js_shared_dict_zone zone=bar:512K timeout=30s evict;\n\n # Creates a 32Kb permanent dictionary with number values:\n js_shared_dict_zone zone=num:32k type=number;\n\nexample.js:\n function get(r) {\n r.return(200, ngx.shared.foo.get(r.args.key));\n }\n\n function set(r) {\n r.return(200, ngx.shared.foo.set(r.args.key, r.args.value));\n }\n\n function del(r) {\n r.return(200, ngx.shared.bar.delete(r.args.key));\n }\n\n function increment(r) {\n r.return(200, ngx.shared.num.incr(r.args.key, 2));\n }\n```", |
| 4982 | + "description_html": "<p>Sets the <em><code>name</code></em> and <em><code>size</code></em> of the shared memory zone\nthat keeps the\nkey-value <a href=\"https://nginx.org/en/docs/njs/reference.html#dict\" target=\"_blank\">dictionary</a>\nshared between worker processes.</p>\n\n<p>By default the shared dictionary uses a string as a key and a value.\nThe optional <code>type</code> parameter\nallows redefining the value type to number.</p>\n\n<p>The optional <code>timeout</code> parameter sets\nthe time in milliseconds\nafter which all shared dictionary entries are removed from the zone.\nIf some entries require a different removal time, it can be set\nwith the <code>timeout</code> argument of the\n<a href=\"https://nginx.org/en/docs/njs/reference.html#dict_add\" target=\"_blank\">add</a>,\n<a href=\"https://nginx.org/en/docs/njs/reference.html#dict_incr\" target=\"_blank\">incr</a>, and\n<a href=\"https://nginx.org/en/docs/njs/reference.html#dict_set\" target=\"_blank\">set</a>\nmethods\n(<a href=\"https://nginx.org/en/docs/njs/changes.html#njs0.8.5\" target=\"_blank\">0.8.5</a>).</p>\n\n<p>The optional <code>evict</code> parameter removes the oldest\nkey-value pair when the zone storage is exhausted.</p>\n\n<p>Example:</p>\n\n<pre><code>example.conf:\n # Creates a 1Mb dictionary with string values,\n # removes key-value pairs after 60 seconds of inactivity:\n js_shared_dict_zone zone=foo:1M timeout=60s;\n\n # Creates a 512Kb dictionary with string values,\n # forcibly removes oldest key-value pairs when the zone is exhausted:\n js_shared_dict_zone zone=bar:512K timeout=30s evict;\n\n # Creates a 32Kb permanent dictionary with number values:\n js_shared_dict_zone zone=num:32k type=number;\n\nexample.js:\n function get(r) {\n r.return(200, ngx.shared.foo.get(r.args.key));\n }\n\n function set(r) {\n r.return(200, ngx.shared.foo.set(r.args.key, r.args.value));\n }\n\n function del(r) {\n r.return(200, ngx.shared.bar.delete(r.args.key));\n }\n\n function increment(r) {\n r.return(200, ngx.shared.num.incr(r.args.key, 2));\n }\n</code></pre>\n" |
4983 | 4983 | },
|
4984 | 4984 | {
|
4985 | 4985 | "name": "js_var",
|
|
14135 | 14135 | "<p><code>zone</code>=<em><code>name</code></em>:<em><code>size</code></em> [<code>timeout</code>=<em><code>time</code></em>] [<code>type</code>=<code>string</code>|<code>number</code>] [<code>evict</code>]</p>\n"
|
14136 | 14136 | ],
|
14137 | 14137 | "isBlock": false,
|
14138 |
| - "description_md": "Sets the *`name`* and *`size`* of the shared memory zone\nthat keeps the\nkey-value [dictionary](https://nginx.org/en/docs/njs/reference.html#dict)\nshared between worker processes.\n\nBy default the shared dictionary uses a string as a key and a value.\nThe optional `type` parameter\nallows redefining the value type to number.\n\nThe optional `timeout` parameter sets\nthe time after which all shared dictionary entries are removed from the zone.\n\nThe optional `evict` parameter removes the oldest\nkey-value pair when the zone storage is exhausted.\n\nExample:\n```\nexample.conf:\n # Creates a 1Mb dictionary with string values,\n # removes key-value pairs after 60 seconds of inactivity:\n js_shared_dict_zone zone=foo:1M timeout=60s;\n\n # Creates a 512Kb dictionary with string values,\n # forcibly removes oldest key-value pairs when the zone is exhausted:\n js_shared_dict_zone zone=bar:512K timeout=30s evict;\n\n # Creates a 32Kb permanent dictionary with number values:\n js_shared_dict_zone zone=num:32k type=number;\n\nexample.js:\n function get(r) {\n r.return(200, ngx.shared.foo.get(r.args.key));\n }\n\n function set(r) {\n r.return(200, ngx.shared.foo.set(r.args.key, r.args.value));\n }\n\n function del(r) {\n r.return(200, ngx.shared.bar.delete(r.args.key));\n }\n\n function increment(r) {\n r.return(200, ngx.shared.num.incr(r.args.key, 2));\n }\n```", |
14139 |
| - "description_html": "<p>Sets the <em><code>name</code></em> and <em><code>size</code></em> of the shared memory zone\nthat keeps the\nkey-value <a href=\"https://nginx.org/en/docs/njs/reference.html#dict\" target=\"_blank\">dictionary</a>\nshared between worker processes.</p>\n\n<p>By default the shared dictionary uses a string as a key and a value.\nThe optional <code>type</code> parameter\nallows redefining the value type to number.</p>\n\n<p>The optional <code>timeout</code> parameter sets\nthe time after which all shared dictionary entries are removed from the zone.</p>\n\n<p>The optional <code>evict</code> parameter removes the oldest\nkey-value pair when the zone storage is exhausted.</p>\n\n<p>Example:</p>\n\n<pre><code>example.conf:\n # Creates a 1Mb dictionary with string values,\n # removes key-value pairs after 60 seconds of inactivity:\n js_shared_dict_zone zone=foo:1M timeout=60s;\n\n # Creates a 512Kb dictionary with string values,\n # forcibly removes oldest key-value pairs when the zone is exhausted:\n js_shared_dict_zone zone=bar:512K timeout=30s evict;\n\n # Creates a 32Kb permanent dictionary with number values:\n js_shared_dict_zone zone=num:32k type=number;\n\nexample.js:\n function get(r) {\n r.return(200, ngx.shared.foo.get(r.args.key));\n }\n\n function set(r) {\n r.return(200, ngx.shared.foo.set(r.args.key, r.args.value));\n }\n\n function del(r) {\n r.return(200, ngx.shared.bar.delete(r.args.key));\n }\n\n function increment(r) {\n r.return(200, ngx.shared.num.incr(r.args.key, 2));\n }\n</code></pre>\n" |
| 14138 | + "description_md": "Sets the *`name`* and *`size`* of the shared memory zone\nthat keeps the\nkey-value [dictionary](https://nginx.org/en/docs/njs/reference.html#dict)\nshared between worker processes.\n\nBy default the shared dictionary uses a string as a key and a value.\nThe optional `type` parameter\nallows redefining the value type to number.\n\nThe optional `timeout` parameter sets\nthe time in milliseconds\nafter which all shared dictionary entries are removed from the zone.\nIf some entries require a different removal time, it can be set\nwith the `timeout` argument of the\n[add](https://nginx.org/en/docs/njs/reference.html#dict_add),\n[incr](https://nginx.org/en/docs/njs/reference.html#dict_incr), and\n[set](https://nginx.org/en/docs/njs/reference.html#dict_set)\nmethods\n([0.8.5](https://nginx.org/en/docs/njs/changes.html#njs0.8.5)).\n\nThe optional `evict` parameter removes the oldest\nkey-value pair when the zone storage is exhausted.\n\nExample:\n```\nexample.conf:\n # Creates a 1Mb dictionary with string values,\n # removes key-value pairs after 60 seconds of inactivity:\n js_shared_dict_zone zone=foo:1M timeout=60s;\n\n # Creates a 512Kb dictionary with string values,\n # forcibly removes oldest key-value pairs when the zone is exhausted:\n js_shared_dict_zone zone=bar:512K timeout=30s evict;\n\n # Creates a 32Kb permanent dictionary with number values:\n js_shared_dict_zone zone=num:32k type=number;\n\nexample.js:\n function get(r) {\n r.return(200, ngx.shared.foo.get(r.args.key));\n }\n\n function set(r) {\n r.return(200, ngx.shared.foo.set(r.args.key, r.args.value));\n }\n\n function del(r) {\n r.return(200, ngx.shared.bar.delete(r.args.key));\n }\n\n function increment(r) {\n r.return(200, ngx.shared.num.incr(r.args.key, 2));\n }\n```", |
| 14139 | + "description_html": "<p>Sets the <em><code>name</code></em> and <em><code>size</code></em> of the shared memory zone\nthat keeps the\nkey-value <a href=\"https://nginx.org/en/docs/njs/reference.html#dict\" target=\"_blank\">dictionary</a>\nshared between worker processes.</p>\n\n<p>By default the shared dictionary uses a string as a key and a value.\nThe optional <code>type</code> parameter\nallows redefining the value type to number.</p>\n\n<p>The optional <code>timeout</code> parameter sets\nthe time in milliseconds\nafter which all shared dictionary entries are removed from the zone.\nIf some entries require a different removal time, it can be set\nwith the <code>timeout</code> argument of the\n<a href=\"https://nginx.org/en/docs/njs/reference.html#dict_add\" target=\"_blank\">add</a>,\n<a href=\"https://nginx.org/en/docs/njs/reference.html#dict_incr\" target=\"_blank\">incr</a>, and\n<a href=\"https://nginx.org/en/docs/njs/reference.html#dict_set\" target=\"_blank\">set</a>\nmethods\n(<a href=\"https://nginx.org/en/docs/njs/changes.html#njs0.8.5\" target=\"_blank\">0.8.5</a>).</p>\n\n<p>The optional <code>evict</code> parameter removes the oldest\nkey-value pair when the zone storage is exhausted.</p>\n\n<p>Example:</p>\n\n<pre><code>example.conf:\n # Creates a 1Mb dictionary with string values,\n # removes key-value pairs after 60 seconds of inactivity:\n js_shared_dict_zone zone=foo:1M timeout=60s;\n\n # Creates a 512Kb dictionary with string values,\n # forcibly removes oldest key-value pairs when the zone is exhausted:\n js_shared_dict_zone zone=bar:512K timeout=30s evict;\n\n # Creates a 32Kb permanent dictionary with number values:\n js_shared_dict_zone zone=num:32k type=number;\n\nexample.js:\n function get(r) {\n r.return(200, ngx.shared.foo.get(r.args.key));\n }\n\n function set(r) {\n r.return(200, ngx.shared.foo.set(r.args.key, r.args.value));\n }\n\n function del(r) {\n r.return(200, ngx.shared.bar.delete(r.args.key));\n }\n\n function increment(r) {\n r.return(200, ngx.shared.num.incr(r.args.key, 2));\n }\n</code></pre>\n" |
14140 | 14140 | },
|
14141 | 14141 | {
|
14142 | 14142 | "name": "js_var",
|
|
16249 | 16249 | ]
|
16250 | 16250 | }
|
16251 | 16251 | ],
|
16252 |
| - "version": "https://github.com/nginx/nginx.org/commit/f5cea0fff718819832c358a7c6d183343deb1f0b" |
| 16252 | + "version": "https://github.com/nginx/nginx.org/commit/5dd1de03c22d985d794ea90c3c6ac0ccb36448a0" |
16253 | 16253 | }
|
0 commit comments