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

59 Commits

Author SHA1 Message Date
Sam Roberts
64cea5a1ac doc: sort bottom-of-file markdown links
Reapply https://github.com/nodejs/node/pull/12726

It would be nice to have the sort check applied as part of doc testing,
but this change doesn't implement that.

PR-URL: https://github.com/nodejs/node/pull/24679
Reviewed-By: Vse Mozhet Byt <vsemozhetbyt@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
2018-11-28 13:09:31 -08:00
koki-oshima
e958ee7a70 doc: use arrow function for anonymous callbacks
PR-URL: https://github.com/nodejs/node/pull/24606
Reviewed-By: Ron Korving <ron@ronkorving.nl>
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com>
Reviewed-By: Vse Mozhet Byt <vsemozhetbyt@gmail.com>
Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com>
2018-11-25 20:32:02 -08:00
Gerhard Stoebich
7cf9a33e0e doc: correct async_hooks sample outputs
Correct the output of async_hooks samples
* `TIMERWRAP` has been removed in #20894
* `console.log()` doesn't issue `TTYWRAP` nor `SIGNALWRAP`

I don't know which PR caused that `console.log()` is no longer using
`TTYWRAP` and `SIGNALWRAP`; I think it was between 8.4.0 and 8.5.0.

PR-URL: https://github.com/nodejs/node/pull/24050
Refs: https://github.com/nodejs/node/pull/20894
Reviewed-By: James M Snell <jasnell@gmail.com>
2018-11-11 20:13:38 +02:00
Sam Roberts
3833d69936 doc: fix some inconsistent use of hostname
host names are DNS names, host addresses are IP addresses, and `host`
arguments and options can be either.

PR-URL: https://github.com/nodejs/node/pull/24199
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
2018-11-09 20:50:02 -08:00
Gerhard Stoebich
7181531742 doc: correct async_hooks resource names
Correct async hooks resource names to match the implementation:
`FSREQWRAP` => `FSREQCALLBACK`
`TCPSERVER` => `TCPSERVERWRAP`

PR-URL: https://github.com/nodejs/node/pull/24001
Refs: https://github.com/nodejs/node/pull/21971
Refs: https://github.com/nodejs/node/pull/17157
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
2018-11-02 22:58:44 +02:00
Ouyang Yadong
5689d55392 doc: add types and their corresponding return values
This commit supplements some types and their corresponding return
values in docs, including `AsyncResource`, `DiffieHellman`,
`ECDH`, `https.Server`, `repl.REPLServer`.

PR-URL: https://github.com/nodejs/node/pull/23998
Reviewed-By: Vse Mozhet Byt <vsemozhetbyt@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
2018-11-02 00:36:40 +02:00
Andreas Madsen
1a2cf6696f
async_hooks: remove promise object from resource
While it doesn't make any difference now. In the future PromiseHooks
could be refactored to provide an asyncId instead of the promise object.
That would make escape analysis on promises possible.

Escape analysis on promises could lead to a more efficient destroy hook,
if provide by PromiseHooks as well. But at the very least would allow
the destroy hook to be emitted earlier. The destroy hook not being
emitted on promises frequent enough is a known and reported issue.
See https://github.com/nodejs/node/issues/14446 and
https://github.com/Jeff-Lewis/cls-hooked/issues/11.

While all this is speculation for now, it all depends on the promise
object not being a part of the PromiseWrap resource object.

Ref: https://github.com/nodejs/node/issues/14446
Ref: https://github.com/nodejs/diagnostics/issues/188

PR-URL: https://github.com/nodejs/node/pull/23443
Refs: https://github.com/nodejs/node/issues/14446
Refs: https://github.com/nodejs/diagnostics/issues/188
Reviewed-By: Benedikt Meurer <benedikt.meurer@gmail.com>
Reviewed-By: Gus Caplan <me@gus.host>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
Reviewed-By: George Adams <george.adams@uk.ibm.com>
2018-10-15 19:40:51 +01:00
Gus Caplan
de0441f6f6
lib: implement queueMicrotask
PR-URL: https://github.com/nodejs/node/pull/22951
Refs: https://html.spec.whatwg.org/multipage/timers-and-user-prompts.html#dom-queuemicrotask
Reviewed-By: Bradley Farias <bradley.meck@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
2018-09-23 15:57:19 -05:00
Vse Mozhet Byt
1a25f9639a doc: remove redundant 'Example:' and similar notes
Some nits were also fixed in passing.

PR-URL: https://github.com/nodejs/node/pull/22537
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: Rich Trott <rtrott@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Sakthipriyan Vairamani <thechargingvolcano@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
2018-08-29 16:53:03 +03:00
Weijia Wang
25840529e3 doc: replace 1 by process.stdout.fd
PR-URL: https://github.com/nodejs/node/pull/22564
Reviewed-By: Vse Mozhet Byt <vsemozhetbyt@gmail.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Jeremiah Senkpiel <fishrock123@rocketmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
2018-08-29 14:01:24 +08:00
Vse Mozhet Byt
3ffbbd3eef doc: prevent some redirections
Replace some redirected URLs with the final ones.

PR-URL: https://github.com/nodejs/node/pull/21811
Reviewed-By: Michaël Zasso <targos@protonmail.com>
Reviewed-By: Jon Moss <me@jonathanmoss.me>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
2018-07-14 22:57:03 +03:00
Anatoli Papirovski
2930bd1317
src: refactor timers to remove TimerWrap
Refactor Timers to behave more similarly to Immediates by having
a single uv_timer_t handle which is stored on the Environment.

No longer expose timers in a public binding and instead make
it part of the internalBinding.

PR-URL: https://github.com/nodejs/node/pull/20894
Fixes: https://github.com/nodejs/node/issues/10154
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
Reviewed-By: Jeremiah Senkpiel <fishrock123@rocketmail.com>
Reviewed-By: Tiancheng "Timothy" Gu <timothygu99@gmail.com>
Reviewed-By: Gus Caplan <me@gus.host>
2018-06-24 21:35:05 -07:00
Anna Henningsen
b7c7c0c496
worker: rename to worker_threads
PR-URL: https://github.com/nodejs/node/pull/20876
Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com>
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com>
Reviewed-By: Shingo Inoue <leko.noor@gmail.com>
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
Reviewed-By: Tiancheng "Timothy" Gu <timothygu99@gmail.com>
Reviewed-By: John-David Dalton <john.david.dalton@gmail.com>
Reviewed-By: Gus Caplan <me@gus.host>
2018-06-06 19:44:15 +02:00
Anna Henningsen
a319b4a398
doc: explain Worker semantics in async_hooks.md
PR-URL: https://github.com/nodejs/node/pull/20876
Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com>
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com>
Reviewed-By: Shingo Inoue <leko.noor@gmail.com>
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
Reviewed-By: Tiancheng "Timothy" Gu <timothygu99@gmail.com>
Reviewed-By: John-David Dalton <john.david.dalton@gmail.com>
Reviewed-By: Gus Caplan <me@gus.host>
2018-06-06 19:44:12 +02:00
Mathias Buus
e5e81f7c19 async_hooks: remove deprecated example
PR-URL: https://github.com/nodejs/node/pull/20998
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Tiancheng "Timothy" Gu <timothygu99@gmail.com>
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com>
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
2018-06-06 01:27:32 -07:00
Vse Mozhet Byt
7588ceaf35 doc: add more missing backticks
Also, fix some other nits in passing
(formatting, punctuation, typos, redundancy, obsoleteness).

PR-URL: https://github.com/nodejs/node/pull/20438
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
2018-05-03 02:12:07 +03:00
Vse Mozhet Byt
a3bd06a5e6 doc: remove redundant empty lines
PR-URL: https://github.com/nodejs/node/pull/20398
Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
2018-04-29 17:48:43 +03:00
Vse Mozhet Byt
6e869be104 doc: unify more headings
PR-URL: https://github.com/nodejs/node/pull/20046
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
2018-04-16 14:04:02 +03:00
Vse Mozhet Byt
9c8857d946 doc: add quotes for event names + fix similar nits
PR-URL: https://github.com/nodejs/node/pull/19915
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com>
2018-04-11 21:42:38 -07:00
Vse Mozhet Byt
de0053cc32 doc: fix various nits
* Replace 2 hyphens (--) by spaced m-dashes (—) as per STYLE_GUIDE.md.
* Space infix operators.
* Unify quotes in inline code spans (use only single quotes).
* Unify `* Returns:` (eliminate deviations).
* Dedupe spaces.

PR-URL: https://github.com/nodejs/node/pull/19743
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com>
2018-04-04 13:45:39 +03:00
Vse Mozhet Byt
237cbe10fb doc,tools: formalize, unify, codify default values
PR-URL: https://github.com/nodejs/node/pull/19737
Reviewed-By: Gus Caplan <me@gus.host>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com>
2018-04-04 12:30:36 +03:00
Rich Trott
9a70b27254 doc: fix punctuation issue in async_hooks.md
Move period incorrectly placed outside of parentheses to inside the
parentheses. The parenthetical in this case is a full sentence.

PR-URL: https://github.com/nodejs/node/pull/19364
Reviewed-By: Daniel Bevenius <daniel.bevenius@gmail.com>
Reviewed-By: Yuta Hiroto <hello@hiroppy.me>
Reviewed-By: Vse Mozhet Byt <vsemozhetbyt@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Gibson Fahnestock <gibfahn@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Tobias Nießen <tniessen@tnie.de>
2018-03-15 14:30:30 -07:00
Rich Trott
e5e0f9f3a8 doc: fix minor issues in async_hooks.md
* easily -> easy
* was -> is
* add a missing comma

PR-URL: https://github.com/nodejs/node/pull/19313
Reviewed-By: Vse Mozhet Byt <vsemozhetbyt@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
2018-03-14 22:36:02 -07:00
Rich Trott
8d336dd8b1 doc: improve text in async_hooks.md
* Remove unnecessary *Note:* designations.
* Various small edits for tone, punctuation, etc.

PR-URL: https://github.com/nodejs/node/pull/19312
Reviewed-By: Vse Mozhet Byt <vsemozhetbyt@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
2018-03-14 22:29:44 -07:00
Sho Miyamoto
646e67e1dc doc: remove Returns: {undefined}
Removed * Returns: {undefined} in doc/ to prevent confusing users

PR-URL: https://github.com/nodejs/node/pull/18951
Reviewed-By: Michaël Zasso <targos@protonmail.com>
Reviewed-By: Vse Mozhet Byt <vsemozhetbyt@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: Tobias Nießen <tniessen@tnie.de>
Reviewed-By: Rich Trott <rtrott@gmail.com>
Reviewed-By: Tiancheng "Timothy" Gu <timothygu99@gmail.com>
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com>
2018-02-26 16:46:55 +02:00
estrada9166
a29089d7c8
doc: add new documentation lint rule
Add 80 characters limit to docs.
Change docs to fit 80 characters per row.

PR-URL: https://github.com/nodejs/node/pull/18726
Fixes: https://github.com/nodejs/node/issues/18703
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
Reviewed-By: Gibson Fahnestock <gibfahn@gmail.com>
Reviewed-By: Anatoli Papirovski <apapirovski@mac.com>
2018-02-23 16:26:29 +00:00
Rich Trott
9cb96ac828 doc: remove extraneous "for example" text
No need to announce obvious example code as being example code. Remove
unneeded "for example" text as one small way to try to keep the docs
more concise..

PR-URL: https://github.com/nodejs/node/pull/18890
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Matheus Marchini <matheus@sthima.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: Vse Mozhet Byt <vsemozhetbyt@gmail.com>
2018-02-23 02:53:21 +02: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
Ali Ijaz Sheikh
9f6a565901 async_hooks: rename PromiseWrap.parentId
Rename the `parentId` property on the PromiseWrap object to a
`isChainedPromise` property. The former wasn't quite useful as it was
always defined to be the same value as the trigger id available in the
init hook. Instead rename the property to be closer to the information
it communicates: whether the promise is a chained promise or not.

PR-URL: https://github.com/nodejs/node/pull/18633
Fixes: https://github.com/nodejs/node/issues/18470
Reviewed-By: Andreas Madsen <amwebdk@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Tiancheng "Timothy" Gu <timothygu99@gmail.com>
2018-02-12 07:13:52 -05:00
Ali Ijaz Sheikh
523a1550a3 async_hooks: deprecate unsafe emit{Before,After}
The emit{Before,After} APIs in AsyncResource are problematic.

* emit{Before,After} are named to suggest that the only thing they do
  is emit the before and after hooks. However, they in fact, mutate
  the current execution context.
* They must be properly nested. Failure to do so by user code leads
  to catastrophic (unrecoverable) exceptions. It is very easy for the
  users to forget that they must be using a try/finally block around
  the code that must be surrounded by these operations. Even the
  example provided in the official docs makes this mistake. Failing
  to use a finally can lead to a catastrophic crash if the callback
  ends up throwing.

This change provides a safer `runInAsyncScope` API as an alternative
and deprecates emit{Before,After}.

PR-URL: https://github.com/nodejs/node/pull/18513
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Andreas Madsen <amwebdk@gmail.com>
2018-02-09 13:03:34 -08:00
James M Snell
d3569b623c
doc: remove **Note:** tags
Remove the various **Note:** prefixes throughout the docs.

PR-URL: https://github.com/nodejs/node/pull/18592
Reviewed-By: Rich Trott <rtrott@gmail.com>
Reviewed-By: Daniel Bevenius <daniel.bevenius@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com>
2018-02-08 11:57:14 -05:00
Ali Ijaz Sheikh
d4b605b990 doc: expand on promises and async_hooks
AsyncHooks have a few subtleties with being able to track promises.
This commit adds a section to the docs that explains things the issues.

PR-URL: https://github.com/nodejs/node/pull/18540
Fixes: https://github.com/nodejs/node/issues/18520
Reviewed-By: James M Snell <jasnell@gmail.com>
2018-02-05 09:36:42 -08:00
Vse Mozhet Byt
fd3a0cfb7c doc: linkify missing types
Also, alphabetize all types in type-parser.js
and fix some nits in type formats.

PR-URL: https://github.com/nodejs/node/pull/18444
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
2018-02-01 02:52:31 +02:00
Matthew Turner
6a56a0a3f8 doc: fix typos in async_hooks
PR-URL: https://github.com/nodejs/node/pull/18314
Reviewed-By: Vse Mozhet Byt <vsemozhetbyt@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
2018-01-23 20:24:58 +02:00
Matthew Turner
55a93756ee doc: fix typo in async_hooks.md
Fix typo in `async_hooks.executionAsyncId()` explanation.

PR-URL: https://github.com/nodejs/node/pull/18286
Reviewed-By: Michaël Zasso <targos@protonmail.com>
Reviewed-By: Minwoo Jung <minwoo@nodesource.com>
Reviewed-By: Vse Mozhet Byt <vsemozhetbyt@gmail.com>
2018-01-22 13:47:10 +02:00
Stephen Belanger
dadf28271c
doc: add change info for async_hooks.executionAsyncId()
Add meta information to async_hooks documentation informing that
executionAsyncId was renamed from currentId at Node.js 8.2.0.

PR-URL: https://github.com/nodejs/node/pull/17813
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Ali Ijaz Sheikh <ofrobots@google.com>
2018-01-18 22:36:58 +01:00
Rich Trott
26607b825e doc: edit for concision
This removes some wordy phrases (notably "it is important to note
that").

PR-URL: https://github.com/nodejs/node/pull/17891
Reviewed-By: Gibson Fahnestock <gibfahn@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com>
2018-01-03 17:18:30 -08:00
sreepurnajasti
b21e3f0711
doc: fix duplicate words & spellings in docs
PR-URL: https://github.com/nodejs/node/pull/17923
Reviewed-By: Vse Mozhet Byt <vsemozhetbyt@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Richard Lau <riclau@uk.ibm.com>
Reviewed-By: Tobias Nießen <tniessen@tnie.de>
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Jon Moss <me@jonathanmoss.me>
2017-12-31 18:14:25 +01:00
Andreas Madsen
b44efded84
async_wrap: add provider types for net server
Adds `TCPSERVERWRAP` and `PIPESERVERWRAP` as provider types. This
makes it possible to distinguish servers from connections.

PR-URL: https://github.com/nodejs/node/pull/17157
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
2017-11-28 02:50:54 +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
Gaara
667f8c642d
doc: correct the wrong added meta data
PR-URL: https://github.com/nodejs/node/pull/17072
Fixes: https://github.com/nodejs/node/issues/17026
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Myles Borins <myles.borins@gmail.com>
2017-11-16 15:30:33 -05:00
Sebastian Mayr
22901d81c9
async_hooks: add destroy event for gced AsyncResources
In cases where libraries create AsyncResources which may be emitting
more events depending on usage, the only way to ensure that destroy is
called properly is by calling it when the resource gets garbage
collected.

Fixes: https://github.com/nodejs/node/issues/16153
PR-URL: https://github.com/nodejs/node/pull/16998
Fixes: https://github.com/nodejs/node/issues/16153
Reviewed-By: Andreas Madsen <amwebdk@gmail.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: James M Snell <jasnell@gmail.com>
2017-11-16 19:58:00 +01:00
James M Snell
8cd940af13 2017-10-31, Version 9.0.0 (Current)
* Older experimental APIs have been removed.
    [[`d731369b1d`](https://github.com/nodejs/node/commit/d731369b1d)]
    [#14414](https://github.com/nodejs/node/pull/14414)

* **Errors**
  * Improvements have been made to `buffer` module error messages.
  * The assignment of static error codes to Node.js error continues:
    * `buffer`
    * `child_process`
    * `console`
    * `crypto`
    * `dns`
    * `events`
    * `fs`
    * `http`
    * `inspector`
    * `net`
    * `path`
    * `process`
    * `querystring`
    * `readline`
    * `repl`
    * `streams`
    * `string_decoder`
    * `timers`
    * `tls`
    * `url`
    * `util`
    * `v8`
    * `zlib`

* **Child Processes**
  * Errors are emitted on process nextTick.

* **Domains**
  * The long-deprecated `.dispose()` method has been removed.

* **fs**
  * The `fs.ReadStream` and `fs.WriteStream` classes now use `destroy()`.
  * `fs` module callbacks are now invoked with an undefined context.

* **HTTP/1**
  * A 400 Bad Request response will now be sent when parsing fails.
  * Socket timeout will be set when the socket connects.
  * A bug causing the request `'error'` event to fire twice was fixed.
  * HTTP clients may now use generic `Duplex` streams in addition to `net.Socket`.

* **Intl**
  * The deprecated `Intl.v8BreakIterator` has been removed.

* **Modules**
  * The `require.resolve()` method now supports using custom lookup paths.

* **OS**
  * The `os.EOL` property is now read-only.

* **Timers**
  * `setTimeout()` will emit a warning if the timeout is larger that the maximum
    32-bit unsigned integer.
2017-10-31 12:59:12 -07:00
Daijiro Wachi
986be03a4c doc: fix doc styles
CONTRIBUTING.md
  + L857: Unused definition
  + L861: Unused definition
  + L863: Unused definition

doc/api/assert.md
  + L719: Unused definition

doc/api/async_hooks.md
  + L460: Missing code-language flag

doc/api/child_process.md
  + L1362: Unused definition

doc/api/dns.md
  + L674: Unused definition

doc/api/esm.md
  + L178: Missing code-language flag

doc/api/http.md
  + L1868: Unused definition
  + L1887: Unused definition
  + L1888: Unused definition
  + L1889: Unused definition
  + L1916: Unused definition
  + L1917: Unused definition

doc/api/https.md
  + L260: Unused definition

doc/api/os.md
  + L1226: Unused definition

doc/api/process.md
  + L1888: Unused definition

doc/api/stream.md
  + L2227: Definitions with the same identifier

doc/guides/writing-and-running-benchmarks.md
  + L1: Missing newline character at end of file

Refs: https://github.com/nodejs/node/pull/12756
PR-URL: https://github.com/nodejs/node/pull/16385
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Anatoli Papirovski <apapirovski@mac.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com>
Reviewed-By: Gibson Fahnestock <gibfahn@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
2017-10-24 18:04:18 +02:00
Jon Moss
19d40f0f60
doc: async_hooks grammar nits
PR-URL: https://github.com/nodejs/node/pull/16361
Reviewed-By: Anatoli Papirovski <apapirovski@mac.com>
Reviewed-By: Rich Trott <rtrott@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
2017-10-22 14:06:56 +02:00
Jon Moss
353040c824 doc: link to async_hooks destroy callback properly
PR-URL: https://github.com/nodejs/node/pull/16351
Reviewed-By: Michaël Zasso <targos@protonmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Vse Mozhet Byt <vsemozhetbyt@gmail.com>
2017-10-21 11:56:27 +03:00
Vse Mozhet Byt
f88178906b doc: fix some links
PR-URL: https://github.com/nodejs/node/pull/16202
Reviewed-By: Daijiro Wachi <daijiro.wachi@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
2017-10-15 02:02:08 +03:00
Gibson Fahnestock
1175c9dca3
doc: standardize function param/object prop style
PR-URL: https://github.com/nodejs/node/pull/13769
Reviewed-By: Vse Mozhet Byt <vsemozhetbyt@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
2017-09-28 02:26:56 -03:00
Anna Henningsen
b605b15346
async_hooks: support promise resolve hook
Add a `promiseResolve()` hook.

PR-URL: https://github.com/nodejs/node/pull/15296
Reviewed-By: Trevor Norris <trev.norris@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
2017-09-23 15:52:03 +02:00
James M Snell
d8a0364ad5 async_hooks,doc: some async_hooks improvements
Update docs and type checking for AsyncResource type

PR-URL: https://github.com/nodejs/node/pull/15103
Reviewed-By: Refael Ackermann <refack@gmail.com>
Reviewed-By: Andreas Madsen <amwebdk@gmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: Trevor Norris <trev.norris@gmail.com>
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
2017-09-15 09:06:13 -07:00