0
0
mirror of https://github.com/nodejs/node.git synced 2024-12-01 16:10:02 +01:00
Commit Graph

1914 Commits

Author SHA1 Message Date
James M Snell
197a465280 zlib: move constants into zlib.constants
zlib constants were previously being added to binding in node_zlib.cc.
This moves the zlib constants to node_constants.cc for consistency with
the recent constants refactoring:
  https://github.com/nodejs/node/pull/6534

Adds require('zlib').constants to expose the constants
Docs-only deprecates the constants hung directly off require('zlib')
Removes a couple constants from the docs that apparently no longer
exist in the code

PR-URL: https://github.com/nodejs/node/pull/7203
Reviewed-By: Rod Vagg <rod@vagg.org>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
2016-06-11 17:24:35 -07:00
James M Snell
a173483619 doc: general improvements to path.md copy
PR-URL: https://github.com/nodejs/node/pull/7122
Reviewed-By: Brian White <mscdex@mscdex.net>
2016-06-11 17:20:57 -07:00
Rich Trott
f2c59d9658 doc: url.format() parameter may be a string
PR-URL: https://github.com/nodejs/node/pull/7235
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: cjihrig - Colin Ihrig <cjihrig@gmail.com>
2016-06-10 21:45:02 -07:00
Rich Trott
60891c6ef0 doc: clarify use of 0 port value
Clarify that using a port value of `0` will result in the operating
system identifying an available port for use.

PR-URL: https://github.com/nodejs/node/pull/7206
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: cjihrig - Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
2016-06-09 22:20:50 -07:00
Jesús Leganés Combarro "piranna
0cd0118334 stream: 'data' argument on callback of Transform._flush()
Add a `data` argument on Transform._flush() callback to be API
consistent with Transform._transform().

Fixes: https://github.com/nodejs/node/issues/3707
PR-URL: https://github.com/nodejs/node/pull/3708
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
2016-06-09 11:06:01 +02:00
cjihrig
779091ffdb doc: remove cluster.setupMaster() myth
cluster.setupMaster() can be called more than once. Core even has
tests for this functionality. This commit removes an incorrect
statement to the contrary from the documentation.

Fixes: https://github.com/nodejs/node/issues/7156
PR-URL: https://github.com/nodejs/node/pull/7179
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Claudio Rodriguez <cjrodr@yahoo.com>
2016-06-08 11:50:32 -04:00
James M Snell
d9e0d8b810
doc: fix minor nit introduced in readline.md
PR-URL: https://github.com/nodejs/node/pull/7198
Reviewed-By: Julian Duque <julianduquej@gmail.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
2016-06-07 18:55:32 -04:00
Trevor Norris
e0b8dd59bc src: remove final trace of raw encoding
A message stuck around in the native API warning users to not use 'raw'
encoding. Followed by an abort(). This is no longer necessary since all
other signs of 'raw' encoding have been removed.

PR-URL: https://github.com/nodejs/node/pull/7111
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: James M Snell <jasnell@gmail.com>
2016-06-07 13:54:24 -06:00
Trevor Norris
54cc7212df buffer: introduce latin1 encoding term
When node began using the OneByte API (f150d56) it also switched to
officially supporting ISO-8859-1. Though at the time no new encoding
string was introduced.

Introduce the new encoding string 'latin1' to be more explicit. The
previous 'binary' and documented as an alias to 'latin1'.  While many
tests have switched to use 'latin1', there are still plenty that do both
'binary' and 'latin1' checks side-by-side to ensure there is no
regression.

PR-URL: https://github.com/nodejs/node/pull/7111
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: James M Snell <jasnell@gmail.com>
2016-06-07 13:51:14 -06:00
James M Snell
c300ba2212 doc: clarify rl.question callback args
Clarify that readline's rl.question() callback does not
use the err back pattern.

Fixes: https://github.com/nodejs/node/issues/4833
PR-URL: https://github.com/nodejs/node/pull/7022
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com>
2016-06-07 07:15:14 -07:00
James M Snell
ed8b600b98 doc: general improvements to readline.md copy
PR-URL: https://github.com/nodejs/node/pull/7022
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com>
2016-06-07 07:15:09 -07:00
Rich Trott
a78c2335b1 doc: use consistent typography in streams.md
In prose, always surround `null`-as-a-value in backticks.

PR-URL: https://github.com/nodejs/node/pull/6986
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Robert Jefe Lindstaedt <robert.lindstaedt@gmail.com>
2016-06-06 17:06:58 -07:00
James M Snell
a32f7eb4be doc: general improvements to process.md copy
PR-URL: https://github.com/nodejs/node/pull/7029
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com>
2016-06-06 14:53:10 -07:00
James M Snell
c339c58c4f doc: general improvements to repl.md copy
The repl documentation has always been rather lacking. This is
a first step towards making significant improvements.

PR-URL: https://github.com/nodejs/node/pull/7002
Reviewed-By: Anna Henningsen <anna@addaleax.net>
2016-06-06 14:49:06 -07:00
Julian Duque
0ed4d8c535 doc: add added: information for readline
Got the information from git history, I added the version when Interface
was exported as class (v0.1.104), it was an internal class on previous
versions.

Refs: https://github.com/nodejs/node/issues/6578
PR-URL: https://github.com/nodejs/node/pull/6996
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: James M Snell <jasnell@gmail.com>
2016-06-06 09:11:14 -07:00
Jonathan Montane
c3e86de9ba doc: improved syntax consistency in console.md
`stdout` was written as `inline code` most of the time,
except for the `console.time` and `console.timeEnd`
functions which made it a bit more tedious to read about.
Now it's always using inline code.

PR-URL: https://github.com/nodejs/node/pull/7062
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Robert Jefe Lindstaedt <robert.lindstaedt@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
2016-06-06 09:07:33 -07:00
Lance Ball
d976d66cfc doc: clarify fs.access works on directories too.
This is maybe more verbose than needed, since the same information is
repeated several times. An alternative, maybe a single short sentence at
the beginning is better. E.g.

Fixes: https://github.com/nodejs/node/issues/7110
PR-URL: https://github.com/nodejs/node/pull/7113
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
2016-06-06 08:46:08 -07:00
James M Snell
80f1fbb00f doc: general improvements to querystring.md copy
PR-URL: https://github.com/nodejs/node/pull/7023
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com>
Reviewed-By: Brian White <mscdex@mscdex.net>
2016-06-06 08:35:19 -07:00
James M Snell
267556762d doc: fix header depth of util.isSymbol
PR-URL: https://github.com/nodejs/node/pull/7138
Reviewed-By: Jeremiah Senkpiel <fishrock123@rocketmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
2016-06-06 08:19:03 -07:00
James M Snell
80ea0c5a64 doc: general improvements to stream.md copy
Majoring restructuring and update for streams doc.
This is the first step of multiple to updating and
correcting the streams documentation.

PR-URL: https://github.com/nodejs/node/pull/6947
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
2016-06-06 08:17:19 -07:00
Julian Duque
71996506e9 doc: add added: information for dns
Got the information from git history and I ignored previous version of
dns attached to `node.dns` (pre v0.1.16).

There is a case where `dns.resolveNaptr` were intented to be in v0.7.12 and
it was reverted and addec back on `v0.9.12`, I left the latest version
when module was introduced. Same for `dns.resolvePtr` who was referenced
before but it was only added on `v6.0.0`

Refs: https://github.com/nodejs/node/issues/6578
PR-URL: https://github.com/nodejs/node/pull/7021
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
2016-06-03 12:32:09 -07:00
Julian Duque
bed44c94a0 doc: add added: information for path
Got the information from git history mostly, I ignored previous path
methods attached to `node.path` (pre v0.1.16).

Refs: https://github.com/nodejs/node/issues/6578
PR-URL: https://github.com/nodejs/node/pull/6985
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: James M Snell <jasnell@gmail.com>
2016-06-03 12:30:17 -07:00
Italo A. Casas
8bccc9e6c8 doc: add added information for net
Ref: https://github.com/nodejs/node/issues/6578
PR-URL: https://github.com/nodejs/node/pull/7038
Reviewed-By: Anna Henningsen <anna@addaleax.net>
2016-06-02 17:15:22 -07:00
James M Snell
83e32266b6 doc: general improvements to punycode.md copy
PR-URL: https://github.com/nodejs/node/pull/7025
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com>
2016-06-02 16:35:56 -07:00
Michael Dawson
138c7af42a doc: add links to platform specific mechanisms
As requested in earlier PR adding detail for Aix, add link
for each of the platform specific technologies used for
file system watching.

PR-URL: https://github.com/nodejs/node/pull/7071
Reviewed-By: Robert Jefe Lindstädt <robert.lindstaedt@gmail.com>
Reviewed-By: Rod Vagg <rod@vagg.org>
Reviewed-By: Yorkie Liu <yorkiefixer@gmail.com>
2016-06-02 11:28:53 -04:00
Jeremiah Senkpiel
98de4abae3 tty: use blocking mode on OS X
OS X has a tiny 1kb hard-coded buffer size for stdout / stderr to
TTYs (terminals). Output larger than that causes chunking, which ends
up having some (very small but existent) delay past the first chunk.
That causes two problems:

1. When output is written to stdout and stderr at similar times, the
two can become mixed together (interleaved). This is especially
problematic when using control characters, such as \r. With
interleaving, chunked output will often have lines or characters erased
unintentionally, or in the wrong spots, leading to broken output.
CLI apps often extensively use such characters for things such as
progress bars.

2. Output can be lost if the process is exited before chunked writes
are finished flushing. This usually happens in applications that use
`process.exit()`, which isn't infrequent.

See https://github.com/nodejs/node/issues/6980 for more info.

This became an issue as result of the Libuv 1.9.0 upgrade. A fix to
an unrelated issue broke a hack previously required for the OS X
implementation. This resulted in an unexpected behavior change in node.
The 1.9.0 upgrade was done in c3cec1eefc,
which was included in v6.0.0.
Full details of the Libuv issue that induced this are at
https://github.com/nodejs/node/issues/6456#issuecomment-219974514

Refs: https://github.com/nodejs/node/pull/1771
Refs: https://github.com/nodejs/node/issues/6456
Refs: https://github.com/nodejs/node/pull/6773
Refs: https://github.com/nodejs/node/pull/6816
PR-URL: https://github.com/nodejs/node/pull/6895
Reviewed-By: Rod Vagg <rod@vagg.org>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
2016-06-01 18:57:45 -04:00
Jeremiah Senkpiel
0cc903544d doc: addresses nits in string_decoder, url, util
- Only `@@toStringTag` affects `util.isError()`, this is the reason why
it uses `Object.prototype.toString.call(argument)` under the hood.
- Shows an actual Euro symbol for reference.
- Uses line-drawing characters for the URL chart & fixes the chart
borders.

PR-URL: https://github.com/nodejs/node/pull/7026
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com>
2016-05-31 10:28:14 -04:00
Pavel Feldman
84ad31fff3 src,lib: v8-inspector support
This change introduces experimental v8-inspector support. This brings
the DevTools debug protocol allowing Node.js to be debugged with
Chrome DevTools native, or through other debuggers supporting that
protocol.

Partial WebSocket support, to the extent required by DevTools, is
included. This is derived from the implementation in Blink.

v8-inspector support can be disabled by the --without-inspector
configure flag.

PR-URL: https://github.com/nodejs/node/pull/6792
Reviewed-By: jasnell - James M Snell <jasnell@gmail.com>
Reviewed-By: addaleax - Anna Henningsen <anna@addaleax.net>
Reviewed-By: bnoordhuis - Ben Noordhuis <info@bnoordhuis.nl>
2016-05-30 09:05:46 -07:00
Rich Trott
112b9cdad7 doc: improve debugger doc prose
PR-URL: https://github.com/nodejs/node/pull/7007
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
2016-05-29 19:28:18 -07:00
Tim Kuijsten
5207526ec8
doc: buffers are not sent over IPC with a socket
If a socket is sent to a child, any data that is buffered in the socket
will not be sent to the child. The child will only receive data from the
socket that is sent after the child has the socket.

PR-URL: https://github.com/nodejs/node/pull/6951
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
2016-05-29 22:58:05 +02:00
Sakthipriyan Vairamani
435e673efd doc: minor improvements to util.md
PR-URL: https://github.com/nodejs/node/pull/6932
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Robert Jefe Lindstaedt <robert.lindstaedt@gmail.com>
Reviewed-By: Brian White <mscdex@mscdex.net>
2016-05-29 12:25:03 +05:30
Anna Henningsen
16f98e589c
doc: add added: information for vm
Ref: https://github.com/nodejs/node/issues/6578
PR-URL: https://github.com/nodejs/node/pull/7011
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Julian Duque <julianduquej@gmail.com>
2016-05-28 16:12:50 +02:00
Adrian Estrada
51b8a79bd4
doc: add added: information for console
Information extracted from git history.

Ref: https://github.com/nodejs/node/issues/6578
PR-URL: https://github.com/nodejs/node/pull/6995
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Julian Duque <julianduquej@gmail.com>
2016-05-28 16:06:05 +02:00
Michael Dawson
8af25a39d3 doc: add info on what's used for fswatch on AIX
Info is provided on for the other OS's. Add similar
level of info for AIX.

PR-URL: https://github.com/nodejs/node/pull/6837
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Santiago Gimeno <santiago.gimeno@gmail.com>
2016-05-27 16:44:32 -04:00
doug.wade
e916218ba5 doc: update process.hrtime docs to include optional parameter
Adds more explicit documentation for the single optional parameter
to process.hrtime to the process docs.

PR-URL: https://github.com/nodejs/node/pull/6585
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Robert Jefe Lindstaedt <robert.lindstaedt@gmail.com>
Reviewed-By: Сковорода Никита Андреевич <chalkerx@gmail.com>
Reviewed-By: Trevor Norris <trev.norris@gmail.com>
2016-05-27 09:28:48 -07:00
Rich Trott
6306b10c48 doc: improve server.listen() documentation prose
PR-URL: https://github.com/nodejs/node/pull/7000
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Yuval Brik <yuval@brik.org.il>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Santiago Gimeno <santiago.gimeno@gmail.com>
2016-05-27 09:00:58 -07:00
Rich Trott
2783978847 doc: improve server.address() doc text
PR-URL: https://github.com/nodejs/node/pull/7001
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Santiago Gimeno <santiago.gimeno@gmail.com>
2016-05-27 08:59:01 -07:00
James M Snell
5d2c0ac9f2 doc: general improvements to tty.md
PR-URL: https://github.com/nodejs/node/pull/6931
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com>
Reviewed-By: Jeremiah Senkpiel <fishrock123@rocketmail.com>
2016-05-27 08:51:34 -07:00
Rich Trott
90675818ee doc: add added: data for cli.md
PR-URL: https://github.com/nodejs/node/pull/6960
Refs: https://github.com/nodejs/node/issues/6578
Reviewed-By: Jeremiah Senkpiel <fishrock123@rocketmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Myles Borins <myles.borins@gmail.com>
2016-05-26 21:02:54 -07:00
Anna Henningsen
27d2267066
doc: add added: information for child_process
Ref: https://github.com/nodejs/node/issues/6578
PR-URL: https://github.com/nodejs/node/pull/6927
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
2016-05-27 04:29:31 +02:00
James M Snell
dbdea02a99 doc: general improvements to url.md copy
General cleanup and restructuring of the doc. Added
additional detail to how URLs are serialized.

PR-URL: https://github.com/nodejs/node/pull/6904
Reviewed-By: Robert Jefe Lindstaedt <robert.lindstaedt@gmail.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Sakthipriyan Vairamani <thechargingvolcano@gmail.com>
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com>
Reviewed-By: Brian White <mscdex@mscdex.net>
2016-05-26 18:09:18 -07:00
James M Snell
1b6a468c72 doc: general improvements to tls.md copy
Restructuring and clarifications to the tls.md copy
to improve readability and flow.

PR-URL: https://github.com/nodejs/node/pull/6933
Reviewed-By: Fedor Indutny <fedor.indutny@gmail.com>
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: Shigeki Ohtsu <ohtsu@iij.ad.jp>
2016-05-26 08:12:33 -07:00
Anna Henningsen
048b3de22d
doc: fix broken references
Fix minor broken references in crypto.md, net.md and domains.md
(which uses `EventEmitter` as a type, of which the anchor in
`events.md` has changed).

PR-URL: https://github.com/nodejs/node/pull/6941
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Roman Reiss <me@silverwind.io>
2016-05-26 00:52:36 +02:00
James M Snell
9140b97848 doc: general improvements to string_decoder.md copy
PR-URL: https://github.com/nodejs/node/pull/6940
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Brian White <mscdex@mscdex.net>
2016-05-25 08:53:34 -07:00
Rod Machen
ed11ac6080 doc: remove "\" within backticks
Ref: https://github.com/nodejs/node/issues/6911
Ref: https://github.com/nodejs/node/pull/5075

PR-URL: https://github.com/nodejs/node/pull/6952
Reviewed-By: Robert Jefe Lindstaedt <robert.lindstaedt@gmail.com>
2016-05-24 23:55:28 +02:00
Steve Mao
cc6a78ebb2
doc: clarify buffer class
Fixes: https://github.com/nodejs/node/issues/6891
PR-URL: https://github.com/nodejs/node/pull/6914
Reviewed-By: Claudio Rodriguez <cjrodr@yahoo.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Сковорода Никита Андреевич <chalkerx@gmail.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
2016-05-24 16:54:18 +02:00
Anna Henningsen
2193a2efcf
doc: reference list of language-specific globals
Fixes: https://github.com/nodejs/node/issues/6894
PR-URL: https://github.com/nodejs/node/pull/6900
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Robert Jefe Lindstaedt <robert.lindstaedt@gmail.com>
2016-05-24 01:21:15 +02:00
James M Snell
ef9778cb9b doc: general improvements to util.md
PR-URL: https://github.com/nodejs/node/pull/6897
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Robert Jefe Lindstaedt <robert.lindstaedt@gmail.com>
2016-05-23 08:00:41 -07:00
Anna Henningsen
b49df88916
doc: add added: information for zlib
Ref: https://github.com/nodejs/node/issues/6578
PR-URL: https://github.com/nodejs/node/pull/6840
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Myles Borins <myles.borins@gmail.com>
Reviewed-By: Robert Jefe Lindstaedt <robert.lindstaedt@gmail.com>
2016-05-23 15:04:13 +02:00
James M Snell
1b7bb2799d doc: general improvements to v8.md copy
PR-URL: https://github.com/nodejs/node/pull/6829
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: Michaël Zasso <mic.besace@gmail.com>
Reviewed-By: Sakthipriyan Vairamani <thechargingvolcano@gmail.com>
2016-05-20 08:37:45 -07:00