From 5ae5ca90effa17a5800ee2ea76429caf03199f3e Mon Sep 17 00:00:00 2001 From: Pranshu Srivastava Date: Sat, 6 Jun 2020 11:57:04 +0530 Subject: [PATCH] doc: add http.IncomingMessage#connection Refs: https://github.com/nodejs/node/issues/33715 * link message.socket * deprecate * update doc/api/http.md PR-URL: https://github.com/nodejs/node/pull/33768 Reviewed-By: Robert Nagy Reviewed-By: James M Snell Reviewed-By: Matteo Collina --- doc/api/deprecations.md | 15 +++++++++++++++ doc/api/http.md | 11 +++++++++++ 2 files changed, 26 insertions(+) diff --git a/doc/api/deprecations.md b/doc/api/deprecations.md index 47b2a5526dcf88..6aaf1c9fd394d0 100644 --- a/doc/api/deprecations.md +++ b/doc/api/deprecations.md @@ -2699,6 +2699,19 @@ resolutions not in `node_modules`. This means there will not be deprecation warnings for `"exports"` in dependencies. With `--pending-deprecation`, a runtime warning results no matter where the `"exports"` usage occurs. + +### DEP0148: `http.IncomingMessage#connection` + + +Type: Documentation-only. + +Prefer [`message.socket`][] over [`message.connection`][]. + [Legacy URL API]: url.md#url_legacy_url_api [NIST SP 800-38D]: https://nvlpubs.nist.gov/nistpubs/Legacy/SP/nistspecialpublication800-38d.pdf [RFC 6066]: https://tools.ietf.org/html/rfc6066#section-3 @@ -2757,6 +2770,8 @@ runtime warning results no matter where the `"exports"` usage occurs. [`http.request()`]: http.md#http_http_request_options_callback [`https.get()`]: https.md#https_https_get_options_callback [`https.request()`]: https.md#https_https_request_options_callback +[`message.connection`]: http.md#http_message_connection +[`message.socket`]: http.md#http_message_socket [`module.createRequire()`]: module.md#module_module_createrequire_filename [`os.networkInterfaces()`]: os.md#os_os_networkinterfaces [`os.tmpdir()`]: os.md#os_os_tmpdir diff --git a/doc/api/http.md b/doc/api/http.md index d01e25576bf49f..809b2b0c44d095 100644 --- a/doc/api/http.md +++ b/doc/api/http.md @@ -1984,6 +1984,16 @@ const req = http.request({ }); ``` +### `message.connection` + + +> Stability: 0 - Deprecated. Use [`message.socket`][]. + +Alias for [`message.socket`][]. + ### `message.destroy([error])`