diff options
author | Jeremiah Senkpiel <fishrock123@rocketmail.com> | 2019-03-18 15:56:49 -0700 |
---|---|---|
committer | Jeremiah Senkpiel <fishrock123@rocketmail.com> | 2019-03-22 19:47:32 -0700 |
commit | 7c80f18c4136af3d819539d466d94e920587bcf4 (patch) | |
tree | 0a2c7f79c16164d998d3885156864ac1742a7bc7 /doc/api/deprecations.md | |
parent | afce91219359654b44df29e6ec1b730e2a73a919 (diff) | |
download | android-node-v8-7c80f18c4136af3d819539d466d94e920587bcf4.tar.gz android-node-v8-7c80f18c4136af3d819539d466d94e920587bcf4.tar.bz2 android-node-v8-7c80f18c4136af3d819539d466d94e920587bcf4.zip |
timers: deprecate active() and _unrefActive()
Another nail in the coffin here, farewell ye ol C-style apis.
These apis caused numerous other issues that required far too many
safeguards. This gets us one step closer to not having to worry about
those issues anymore.
Refs: https://github.com/nodejs/node/pull/18066
Refs: https://github.com/nodejs/node/pull/20298
PR-URL: https://github.com/nodejs/node/pull/26760
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: Anatoli Papirovski <apapirovski@mac.com>
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com>
Diffstat (limited to 'doc/api/deprecations.md')
-rw-r--r-- | doc/api/deprecations.md | 35 |
1 files changed, 35 insertions, 0 deletions
diff --git a/doc/api/deprecations.md b/doc/api/deprecations.md index a26e2506d0..b23ee43ba5 100644 --- a/doc/api/deprecations.md +++ b/doc/api/deprecations.md @@ -2368,6 +2368,38 @@ Type: Runtime The `_stream_wrap` module is deprecated. +<a id="DEP0126"></a> +### DEP0126: timers.active() +<!-- YAML +changes: + - version: REPLACEME + pr-url: https://github.com/nodejs/node/pull/26760 + description: Runtime deprecation. +--> + +Type: Runtime + +The previously undocumented `timers.active()` is deprecated. +Please use the publicly documented [`timeout.refresh()`][] instead. +If re-referencing the timeout is necessary, [`timeout.ref()`][] can be used +with no performance impact since Node.js 10. + +<a id="DEP0127"></a> +### DEP0127: timers._unrefActive() +<!-- YAML +changes: + - version: REPLACEME + pr-url: https://github.com/nodejs/node/pull/26760 + description: Runtime deprecation. +--> + +Type: Runtime + +The previously undocumented and "private" `timers._unrefActive()` is deprecated. +Please use the publicly documented [`timeout.refresh()`][] instead. +If unreferencing the timeout is necessary, [`timeout.unref()`][] can be used +with no performance impact since Node.js 10. + [`--pending-deprecation`]: cli.html#cli_pending_deprecation [`Buffer.allocUnsafeSlow(size)`]: buffer.html#buffer_class_method_buffer_allocunsafeslow_size [`Buffer.from(array)`]: buffer.html#buffer_class_method_buffer_from_array @@ -2423,6 +2455,9 @@ The `_stream_wrap` module is deprecated. [`script.createCachedData()`]: vm.html#vm_script_createcacheddata [`setInterval()`]: timers.html#timers_setinterval_callback_delay_args [`setTimeout()`]: timers.html#timers_settimeout_callback_delay_args +[`timeout.ref()`]: timers.html#timers_timeout_ref +[`timeout.refresh()`]: timers.html#timers_timeout_refresh +[`timeout.unref()`]: timers.html#timers_timeout_unref [`tls.CryptoStream`]: tls.html#tls_class_cryptostream [`tls.SecureContext`]: tls.html#tls_tls_createsecurecontext_options [`tls.SecurePair`]: tls.html#tls_class_securepair |