Skip to content

perf: use node: prefix to bypass require.cache call for builtins#81

Merged
Uzlopak merged 1 commit intomasterfrom
perf/builtins
Sep 10, 2023
Merged

perf: use node: prefix to bypass require.cache call for builtins#81
Uzlopak merged 1 commit intomasterfrom
perf/builtins

Conversation

@Fdawgs
Copy link
Member

@Fdawgs Fdawgs commented Sep 10, 2023

See fastify/fastify-static#407

Checklist

Copy link
Contributor

@Uzlopak Uzlopak left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@Uzlopak Uzlopak merged commit 41b5f61 into master Sep 10, 2023
@Fdawgs Fdawgs deleted the perf/builtins branch September 10, 2023 09:11
@LucasHang
Copy link

Pointing out that applications using node versions under 16 will break. At least it happened with my fragile version 14-alpine on Dockerfile 😢

@climba03003
Copy link
Member

climba03003 commented Nov 8, 2023

@LucasHang
node: prefix is supported in 14.x.
You can pull the latest 14-alpine again to at least reach 14.18.0 version.
Keeping the base image up-to-date is important.

@LucasHang
Copy link

@LucasHang
node: prefix is supported in 14.x.
You can pull the latest 14-alpine again to at least reach 14.18.0 version.
Keeping the base image up-to-date is important.

Oh sorry, my bad. Taking a quick look on node docs I only found the package "util" being imported with "node:" on version 16.x, then I felt the need of pointing out, thinking it to be a breaking change.
Thanks for clarifying.

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants