-
Notifications
You must be signed in to change notification settings - Fork 978
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Replace util.promisify
with direct promise based functions
#3919
Comments
|
|
|
|
|
|
Issue Resolve opensearch-project#3919 Signed-off-by: ananzh <ananzh@amazon.com>
Starting from Node.js 8 onwards, most of the core APIs in Node.js have been updated to support native Promises, making the use of
util.promisify
less relevant for newer versions of Node.js.util.promisify
was initially introduced to convert callback-based APIs to Promise-based APIs, making it easier to work with asynchronous code using async/await. With the addition of native Promise support in core APIs, there is no longer a need to usepromisify
for these functions, as you can now directly use the Promise-based versions of them.As part of Node.js 18 bump work #3601, we decide to remove all the
promisify
usages in the repo. This is a research and document task to record all the changes.The text was updated successfully, but these errors were encountered: