Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

doc: add PerformanceObserver buffered document #39514

Closed

Conversation

legendecas
Copy link
Member

@legendecas legendecas commented Jul 25, 2021

The option buffered is not about queueing the PerformanceEntrys with
an event loop task or not. The option buffered in the spec is about filling
the observer with the global PerformanceEntry buffer. The current
(and the spec) behavior is different with Node.js version <= v16.0.0.

Node.js v14.x: buffered If true, the notification callback will be called using setImmediate() and multiple PerformanceEntry instance notifications will be buffered internally. If false, notifications will be immediate and synchronous. Default: false.

Refs: https://w3c.github.io/performance-timeline/#observe-method
Refs: https://nodejs.org/dist/latest-v14.x/docs/api/perf_hooks.html#perf_hooks_performanceobserver_observe_options
Refs: #39297

@legendecas legendecas requested a review from jasnell July 25, 2021 15:56
@nodejs-github-bot nodejs-github-bot added doc Issues and PRs related to the documentations. perf_hooks Issues and PRs related to the implementation of the Performance Timing API. labels Jul 25, 2021
@legendecas legendecas force-pushed the doc/perf_hooks_observe_buffered branch from c92dbbf to d09b20d Compare July 25, 2021 15:58
The option `buffered` is not about queueing the `PerformanceEntry`s with
loop or not. The current (and the spec) behavior is different with
Node.js version <= v16.0.0
@legendecas legendecas force-pushed the doc/perf_hooks_observe_buffered branch from d09b20d to f2af078 Compare July 25, 2021 16:16
@@ -585,6 +585,10 @@ Disconnects the `PerformanceObserver` instance from all notifications.
<!-- YAML
added: v8.5.0
changes:
- version: REPLACEME
pr-url: https://github.com/nodejs/node/pull/39297

This comment was marked as resolved.

@legendecas
Copy link
Member Author

Landed in 497e5f8

@legendecas legendecas closed this Jul 27, 2021
legendecas added a commit that referenced this pull request Jul 27, 2021
The option buffered is not about queueing the PerformanceEntrys with
an event loop task or not. The option buffered in the spec is about
filling the observer with the global PerformanceEntry buffer. The
current (and the spec) behavior is different with Node.js
version <= v16.0.0.

PR-URL: #39514
Refs: https://w3c.github.io/performance-timeline/#observe-method
Refs: https://nodejs.org/dist/latest-v14.x/docs/api/perf_hooks.html#perf_hooks_performanceobserver_observe_options
Refs: #39297
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com>
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com>
@legendecas legendecas deleted the doc/perf_hooks_observe_buffered branch July 27, 2021 16:29
targos pushed a commit that referenced this pull request Aug 2, 2021
The option buffered is not about queueing the PerformanceEntrys with
an event loop task or not. The option buffered in the spec is about
filling the observer with the global PerformanceEntry buffer. The
current (and the spec) behavior is different with Node.js
version <= v16.0.0.

PR-URL: #39514
Refs: https://w3c.github.io/performance-timeline/#observe-method
Refs: https://nodejs.org/dist/latest-v14.x/docs/api/perf_hooks.html#perf_hooks_performanceobserver_observe_options
Refs: #39297
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com>
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com>
danielleadams pushed a commit that referenced this pull request Aug 16, 2021
The option buffered is not about queueing the PerformanceEntrys with
an event loop task or not. The option buffered in the spec is about
filling the observer with the global PerformanceEntry buffer. The
current (and the spec) behavior is different with Node.js
version <= v16.0.0.

PR-URL: #39514
Refs: https://w3c.github.io/performance-timeline/#observe-method
Refs: https://nodejs.org/dist/latest-v14.x/docs/api/perf_hooks.html#perf_hooks_performanceobserver_observe_options
Refs: #39297
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com>
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
doc Issues and PRs related to the documentations. perf_hooks Issues and PRs related to the implementation of the Performance Timing API.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants