[nginx-announce] njs-0.6.2

Dmitry Volyntsev xeioex at nginx.com
Tue Aug 31 15:55:30 UTC 2021


I'm glad to announce a new release of NGINX JavaScript module (njs).

This release proceeds to extend the coverage of ECMAScript

Notable new features:
- Advanced Promise constructor methods
: Promise.all(urls.map(u => ngx.fetch(u)))
: .then(responses => r.return(200, JSON.stringify(responses)))

Learn more about njs:

- Overview and introduction: https://nginx.org/en/docs/njs/
- NGINX JavaScript in Your Web Server Configuration:
- Extending NGINX with Custom Code: https://youtu.be/0CVhq4AUU7M
- Using node modules with njs:
- Writing njs code using TypeScript definition files:

Feel free to try it and give us feedback on:

- Github: https://github.com/nginx/njs/issues
- Mailing list: https://mailman.nginx.org/mailman/listinfo/nginx-devel

Changes with njs 0.6.2                                        31 Aug 2021

     nginx modules:

     *) Bugfix: fixed CPU hog when js_filter is registered
        in both directions.


     *) Feature: introduced AggregateError implementation.

     *) Feature: added remaining Promise constructor methods.
        The following methods were added: Promise.all(),
        Promise.allSettled(), Promise.any(), Promise.race().

     *) Improvement: removed recursion from code generator.

     *) Bugfix: fixed rest parameter parsing without binding

     *) Bugfix: fixed resolve/reject callback for

     *) Bugfix: fixed %TypedArray%.prototype.join() with
        detached buffer.

     *) Bugfix: fixed memory leak in interactive shell.

More information about the nginx-announce mailing list