Skip to content

Commit acc1578

Browse files
committed
doc: deprecate Server.prototype._listen2 in node:net
Signed-off-by: Antoine du Hamel <duhamelantoine1995@gmail.com> PR-URL: #65593 Refs: #63249 Refs: #64794 Reviewed-By: Filip Skokan <panva.ip@gmail.com> Reviewed-By: Tim Perry <pimterry@gmail.com>
1 parent e36633a commit acc1578

1 file changed

Lines changed: 20 additions & 0 deletions

File tree

‎doc/api/deprecations.md‎

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4503,6 +4503,25 @@ throwing an error. This behavior is inconsistent with `hash.digest()` and
45034503
may lead to subtle bugs. Calling `hmac.digest()` on a finalized `Hmac` instance
45044504
will throw an error in a future version.
45054505
4506+
<!-- md-lint skip-deprecation DEP0207 -->
4507+
4508+
### DEP0208: `Server.prototype._listen2`
4509+
4510+
<!-- YAML
4511+
changes:
4512+
- version: REPLACEME
4513+
pr-url: https://github.com/nodejs/node/pull/64794
4514+
description: Documentation-only.
4515+
-->
4516+
4517+
Type: Documentation-only
4518+
4519+
`net.Server.prototype._listen2` is an undocumented alias for an internal
4520+
function that sets up the listening handle. It is kept only so that code
4521+
replacing it keeps being called by [`server.listen()`][], and it will be
4522+
removed in a future version of Node.js. Use [`server.listen()`][] instead of
4523+
calling or overriding `_listen2`.
4524+
45064525
[DEP0142]: #dep0142-repl_builtinlibs
45074526
[NIST SP 800-38D]: https://nvlpubs.nist.gov/nistpubs/Legacy/SP/nistspecialpublication800-38d.pdf
45084527
[RFC 6066]: https://tools.ietf.org/html/rfc6066#section-3
@@ -4634,6 +4653,7 @@ will throw an error in a future version.
46344653
[`response.writableEnded`]: http.md#responsewritableended
46354654
[`response.writableFinished`]: http.md#responsewritablefinished
46364655
[`script.createCachedData()`]: vm.md#scriptcreatecacheddata
4656+
[`server.listen()`]: net.md#serverlisten
46374657
[`setInterval()`]: timers.md#setintervalcallback-delay-args
46384658
[`setTimeout()`]: timers.md#settimeoutcallback-delay-args
46394659
[`socket.bufferSize`]: net.md#socketbuffersize

0 commit comments

Comments
 (0)