-
Notifications
You must be signed in to change notification settings - Fork 13
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
Use vanilla AsyncLocalStorage
instead of asynchronous-local-storage
#158
Conversation
@Fdawgs How can we remove Node 14 from CI if standard workflow is used? |
If some inspiration is needed, then this is how I make the version range possible to overide in my personal standard workflows: https://github.com/voxpelli/ghatemplates/blob/c740bdbac71aec173a791c0dc15b41f0bfca72ef/.github/workflows/test.yml#L11-L15 |
there are conflicts after last PR was merged |
Fixes fastify#148 Signed-off-by: Pelle Wessman <pelle@kodfabrik.se>
824e1db
to
1c32eae
Compare
@kibertoad Conflict fix + feedback responded to / fixed. |
@voxpelli It seems to work fine on Node 14 too, btw. Should we add engine entry to package.json instead? afair, it needs > specific minor version. |
@kibertoad Its marked as experimental in Node 14, but since Node 14 is no longer being updated I guess that experimental status is now kind of no different to it being stable, as the experimental status only meant that it could receive breaking changes in minor/patch releases? So I guess we could just merge and ship as is? Without specifying anything new? An engine definition in the package.json is always nice though |
I will add tomorrow 👍 |
@voxpelli Now I wonder if recreating defaultValues on every request is even necessary with how ALS works. can you write a test that would be failing unless we are creating fresh copy every time? |
Sure, I think #136 already added tests to ensure that for the factory, I'll borrow them and verify it |
It seems that tests are still passing on Node v14. |
Actually, yes, Node 14 is good: https://github.com/kibertoad/asynchronous-local-storage/blob/master/lib/nodeVersionUtils.ts so we only need missing tests and we are good |
@kibertoad Tests been added and verified ✔️ |
@voxpelli thanks! do tests fail if we don't use fresh copy each time? |
@kibertoad Yes the tests fail then. Though this is not an issue in the current code as the current code creates a new |
@voxpelli Thanks a lot! Are you planning any more changes, or can I release next semver major? |
@kibertoad No more changes planned! 🙏 |
Fixes #148 by removing
asynchronous-local-storage
in favor of built inAsyncLocalStorage
Requires that Node.js v14 is dropped.
Checklist
npm run test
andnpm run benchmark
documentation is changed or addedand the Code of conduct