こんにちは、LinuCエバンジェリストこと、鯨井貴博@opensourcetechです。
nginx njs-0.4.0がリリースされました。
Changelogs
更新内容は、以下の通り。
http://nginx.org/en/docs/njs/changes.html
Changes with njs 0.4.0
Release Date: 23 April 2020
nginx modules:
Feature: added support for multi-value headers in r.headersOut{}.
Feature: added js_import directive for http and stream.
Improvement: improved iteration over r.headersOut{} with special headers.
Improvement: improved iteration over r.headersOut{} with duplicates.
Change: r.responseBody property handler now returns undefined instead of throwing an exception if the response body is not available.
Core:
Feature: added script arguments support in CLI.
Feature: converting externals values to native js objects.
Bugfix: fixed NULL-pointer dereference in __proto__ property handler.
Bugfix: fixed handling of no-newline at the end of the script.
Bugfix: fixed RegExp() constructor with empty pattern and non-empty flags.
Bugfix: fixed String.prototype.replace() when function returns non-string.
Bugfix: fixed reading of pseudofiles in fs.
Changelogs(日本語訳)
日本語訳は、以下となります。
Changes with njs 0.4.0
Release Date: 23 April 2020
nginxモジュール:
機能追加:r.headersOut{}で複数値ヘッダーのサポートが追加された。
機能追加:httpとstreamのjs_importディレクティブが追加された。
改善:特別なヘッダを持つr.headersOut{}よりも改善された反復。
改善:重複があるr.headersOut{}よりも改善された反復。
変更:r.responseBodyプロパティハンドラが、レスポンスボディーが使用できない場合に例外をスローするのではなく、undefinedを返すようになりました。
Coreモジュール:
機能追加:CLIでのスクリプト引数のサポートが追加された。
機能追加:外部値をネイティブjsオブジェクトに変換する。
バグ修正:_proto__propertyハンドラ内のNULLポインタの参照解除の修正。
バグ修正:スクリプト終了時のno-newlineの処理が修正された。
バグ修正:空のパターンと空でないフラグを持つRegExp()コンストラクタが修正された。
バグ修正:関数が文字列以外を返す場合の、String.prototype.replace()が修正された。
バグ修正:fsのpseudofilesの読み取りが修正された。