@@ -3102,6 +3102,24 @@ parameter in [`fs.write()`][], [`fs.writeFile()`][], [`fs.appendFile()`][],
3102
3102
[ ` fs.writeFileSync() ` ] [ ] , and [ ` fs.appendFileSync() ` ] [ ] is deprecated.
3103
3103
Convert them to primitive strings.
3104
3104
3105
+ ### DEP0163: ` channel.subscribe(onMessage) ` , ` channel.unsubscribe(onMessage) `
3106
+
3107
+ <!-- YAML
3108
+ changes:
3109
+ - version: REPLACEME
3110
+ pr-url: https://github.com/nodejs/node/pull/42714
3111
+ description: Documentation-only deprecation.
3112
+ -->
3113
+
3114
+ Type: Documentation-only
3115
+
3116
+ These methods were deprecated because they can be used in a way which does not
3117
+ hold the channel reference alive long enough to receive the events.
3118
+
3119
+ Use [ ` diagnostics_channel.subscribe(name, onMessage) ` ] [ ] or
3120
+ [ ` diagnostics_channel.unsubscribe(name, onMessage) ` ] [ ] which does the same
3121
+ thing instead.
3122
+
3105
3123
[ Legacy URL API ] : url.md#legacy-url-api
3106
3124
[ NIST SP 800-38D ] : https://nvlpubs.nist.gov/nistpubs/Legacy/SP/nistspecialpublication800-38d.pdf
3107
3125
[ RFC 6066 ] : https://tools.ietf.org/html/rfc6066#section-3
@@ -3142,6 +3160,8 @@ Convert them to primitive strings.
3142
3160
[ `crypto.scrypt()` ] : crypto.md#cryptoscryptpassword-salt-keylen-options-callback
3143
3161
[ `decipher.final()` ] : crypto.md#decipherfinaloutputencoding
3144
3162
[ `decipher.setAuthTag()` ] : crypto.md#deciphersetauthtagbuffer-encoding
3163
+ [ `diagnostics_channel.subscribe(name, onMessage)` ] : diagnostics_channel.md#diagnostics_channelsubscribename-onmessage
3164
+ [ `diagnostics_channel.unsubscribe(name, onMessage)` ] : diagnostics_channel.md#diagnostics_channelunsubscribename-onmessage
3145
3165
[ `dns.lookup()` ] : dns.md#dnslookuphostname-options-callback
3146
3166
[ `dnsPromises.lookup()` ] : dns.md#dnspromiseslookuphostname-options
3147
3167
[ `domain` ] : domain.md
0 commit comments