0
0
mirror of https://github.com/nodejs/node.git synced 2024-11-29 15:06:33 +01:00
Commit Graph

14 Commits

Author SHA1 Message Date
James M Snell
9e509b622b perf_hooks: emit trace events for marks, measures, and timerify
Adds the `node.perf.usertiming` trace events category for recording
usertiming marks and measures (e.g. `perf_hooks.performance.mark()`)
in the trace events timeline.

Adds the `node.perf.function` trace events category for recording
`perf_hooks.performance.timerify()` durations in the trace events
timeline.

PR-URL: https://github.com/nodejs/node/pull/18789
Reviewed-By: Ali Ijaz Sheikh <ofrobots@google.com>
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
2018-02-26 13:55:33 -08:00
Myles Borins
945eb1bb69
2018-02-22, Version 9.6.0 (Current)
Notable changes:

* async_hooks:
  - deprecate unsafe emit{Before,After} (Ali Ijaz Sheikh)
    https://github.com/nodejs/node/pull/18513
  - rename PromiseWrap.parentId to PromiseWrap.isChainedPromise
    (Ali Ijaz Sheikh) https://github.com/nodejs/node/pull/18633
* deps:
  - update node-inspect to 1.11.3 (Jan Krems)
    https://github.com/nodejs/node/pull/18354
  - ICU 60.2 bump (Steven R. Loomis)
    https://github.com/nodejs/node/pull/17687
  - Introduce ScriptOrModule and HostDefinedOptions to V8 (Jan Krems)
    https://github.com/nodejs/node/pull/16889
* http:
  - add options to http.createServer() for `IncomingMessage` and
    `ServerReponse` (Peter Marton)
    https://github.com/nodejs/node/pull/15752
* http2:
  - add http fallback options to .createServer (Peter Marton)
    https://github.com/nodejs/node/pull/15752
* https:
  - Adds the remaining options from tls.createSecureContext() to the
    string generated by Agent#getName(). This allows https.request()
    to accept the options and generate unique sockets appropriately.
    (Jeff Principe)
    https://github.com/nodejs/node/pull/16402
* inspector:
  - --inspect-brk for es modules (Guy Bedford)
    https://github.com/nodejs/node/pull/18194
* lib:
  - allow process kill by signal number (Sam Roberts)
    https://github.com/nodejs/node/pull/16944
* module:
  - enable dynamic import (Myles Borins)
    https://github.com/nodejs/node/pull/18387
  - dynamic import is now supported (Jan Krems)
    https://github.com/nodejs/node/pull/15713
* napi:
  - add methods to open/close callback scope (Michael Dawson)
    https://github.com/nodejs/node/pull/18089
* src:
  - allow --perf-(basic-)?prof in NODE_OPTIONS (Leko)
    https://github.com/nodejs/node/pull/17600
* vm:
  - add support for es modules (Gus Caplan)
    https://github.com/nodejs/node/pull/17560

PR-URL: https://github.com/nodejs/node/pull/18902
2018-02-22 12:02:49 -05:00
Evan Lucas
83d0f4c92b 2018-01-31, Version 9.5.0 (Current)
Notable changes:

* cluster
  - add cwd to cluster.settings (cjihrig) [#18399](https://github.com/nodejs/node/pull/18399)
* deps
  - upgrade libuv to 1.19.1 (cjihrig) [#18260](https://github.com/nodejs/node/pull/18260)
* meta
  - add Leko to collaborators (Leko) [#18117](https://github.com/nodejs/node/pull/18117)
  - add vdeturckheim as collaborator (vdeturckheim) [#18432](https://github.com/nodejs/node/pull/18432)
* n-api
  - expose n-api version in process.versions (Michael Dawson) [#18067](https://github.com/nodejs/node/pull/18067)
* perf_hooks
  - add performance.clear() (James M Snell) [#18046](https://github.com/nodejs/node/pull/18046)
* stream
  - avoid writeAfterEnd() while ending (陈刚) [#18170](https://github.com/nodejs/node/pull/18170)

PR-URL: https://github.com/nodejs/node/pull/18464
2018-01-31 18:06:32 -06:00
James M Snell
6bcd31f2f4 perf_hooks: add warning when too many entries in the timeline
PR-URL: https://github.com/nodejs/node/pull/18087
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
2018-01-31 15:24:58 -08:00
Antony Tran
d8263a0677 doc: add doc for performance.clearGC()
PR-URL: https://github.com/nodejs/node/pull/18331
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Khaidi Chu <i@2333.moe>
Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com>
2018-01-24 13:39:57 +02:00
James M Snell
20fe04f113 perf_hooks,http2: add performance.clear()
Add missing clear() method to `perf_hooks.performance` to
remove the entries from the master timeline to prevent
that from being a memory leak.

PR-URL: https://github.com/nodejs/node/pull/18046
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
2018-01-11 10:41:49 -08:00
Tobias Nießen
d74a1ed7d9
doc: remove duplicate words in API docs
PR-URL: https://github.com/nodejs/node/pull/17937
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Vse Mozhet Byt <vsemozhetbyt@gmail.com>
2018-01-02 00:13:02 +01:00
Luigi Pinca
97ba69f915 doc: add missing introduced_in comments
Add missing "introduced_in" comments for alternative version links.

PR-URL: https://github.com/nodejs/node/pull/16741
Reviewed-By: Anatoli Papirovski <apapirovski@mac.com>
2017-11-19 18:10:05 +01:00
Sam Roberts
dd83b5f2ac perf_hooks: remove docs for unimplemented API
The node frame (aka loop) timing API did not land, it depends on
https://github.com/libuv/libuv/pull/1489 which is still a WIP.

See: https://github.com/nodejs/node/pull/14680#discussion_r140605664

PR-URL: https://github.com/nodejs/node/pull/15641
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Timothy Gu <timothygu99@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Jeremiah Senkpiel <fishrock123@rocketmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
2017-09-29 09:38:48 -07:00
Mani Maghsoudlou
049a8d7c1d
doc: fix entryTypes type and missing link
PR-URL: https://github.com/nodejs/node/pull/15406
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
2017-09-19 16:36:30 -03:00
Myles Borins
a10856a7d3
2017-09-12, Version 8.5.0 (Current)
Notable Changes

* build:
  * Snapshots are now re-enabled in V8
  https://github.com/nodejs/node/pull/14875

* console:
  * Implement minimal `console.group()`.
  https://github.com/nodejs/node/pull/14910

* deps:
  * upgrade libuv to 1.14.1
    https://github.com/nodejs/node/pull/14866
  * update nghttp2 to v1.25.0
    https://github.com/nodejs/node/pull/14955

* dns:
  * Add `verbatim` option to dns.lookup(). When true, results from the
    DNS resolver are passed on as-is, without the reshuffling that
    Node.js otherwise does that puts IPv4 addresses before IPv6
    addresses.
    https://github.com/nodejs/node/pull/14731

* fs:
  * add fs.copyFile and fs.copyFileSync which allows for more efficient
    copying of files.
    https://github.com/nodejs/node/pull/15034

* inspector:
  * Enable async stack traces
    https://github.com/nodejs/node/pull/13870

* module:
  * Add support for ESM. This is currently behind the
    `--experimental-modules` flag and requires the .mjs extension.
    `node --experimental-modules index.mjs`
    https://github.com/nodejs/node/pull/14369

* napi:
  * implement promise
    https://github.com/nodejs/node/pull/14365

* os:
  * Add support for CIDR notation to the output of the
    networkInterfaces() method.
    https://github.com/nodejs/node/pull/14307

* perf_hooks:
  * An initial implementation of the Performance Timing API for
    Node.js. This is the same Performance Timing API implemented by
    modern browsers with a number of Node.js specific properties. The
    User Timing mark() and measure() APIs are implemented, as is a
    Node.js specific flavor of the Frame Timing for measuring event
    loop duration.
    https://github.com/nodejs/node/pull/14680

* tls:
  * multiple PFX in createSecureContext
    [#14793](https://github.com/nodejs/node/pull/14793)

* Added new collaborators:
  * BridgeAR – Ruben Bridgewater

PR-URL: https://github.com/nodejs/node/pull/15308
2017-09-12 17:34:51 +02:00
Anna Henningsen
dd52cad044 doc,lib,src,test: strip executable bits off files
Remove the executable bits of the file modes of some files that
accidentally received it.

PR-URL: https://github.com/nodejs/node/pull/15132
Reviewed-By: Timothy Gu <timothygu99@gmail.com>
Reviewed-By: Michaël Zasso <targos@protonmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
2017-09-01 10:09:41 -07:00
James M Snell
6db825ae82 perf_hooks: mark as experimental
PR-URL: https://github.com/nodejs/node/pull/14997
Reviewed-By: Refael Ackermann <refack@gmail.com>
Reviewed-By: Timothy Gu <timothygu99@gmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: Daniel Bevenius <daniel.bevenius@gmail.com>
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Jeremiah Senkpiel <fishrock123@rocketmail.com>
2017-08-25 16:04:21 -07:00
James M Snell
67269fd7f3 perf_hooks: implementation of the perf timing API
An initial implementation of the Performance Timing API for Node.js.
This is the same Performance Timing API implemented by modern browsers
with a number of Node.js specific properties. The User Timing mark()
and measure() APIs are implemented, garbage collection timing, and
node startup milestone timing.

```js
const { performance } = require('perf_hooks');

performance.mark('A');
setTimeout(() => {
  performance.mark('B');
  performance.measure('A to B', 'A', 'B');
  const entry = performance.getEntriesByName('A to B', 'measure')[0];
  console.log(entry.duration);
}, 10000);
```

The implementation is at the native layer and makes use of uv_hrtime().
This should enable *eventual* integration with things like Tracing
and Inspection.

The implementation is extensible and should allow us to add new
performance entry types as we go (e.g. for measuring i/o perf,
etc).

Documentation and a test are provided.

PR-URL: https://github.com/nodejs/node/pull/14680
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
2017-08-23 16:00:09 -07:00