Skip to content
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

Evaluate possiblity of moving away from async_hooks #64

Open
jonkoops opened this issue Jun 21, 2024 · 0 comments
Open

Evaluate possiblity of moving away from async_hooks #64

jonkoops opened this issue Jun 21, 2024 · 0 comments

Comments

@jonkoops
Copy link
Collaborator

Currently why-is-node-running depends on Node.js' async-hooks API, however this API is actively recommended against by the Node.js documentation:

Please migrate away from this API, if you can. We do not recommend using the createHook, AsyncHook, and executionAsyncResource APIs as they have usability issues, safety risks, and performance implications. Async context tracking use cases are better served by the stable AsyncLocalStorage API. If you have a use case for createHook, AsyncHook, or executionAsyncResource beyond the context tracking need solved by AsyncLocalStorage or diagnostics data currently provided by Diagnostics Channel, please open an issue at https://github.com/nodejs/node/issues describing your use case so we can create a more purpose-focused API.

This makes it worth investigating whether it is possible to move away from this API, and if so move to one of the APIs outlined in the documentation.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant