- Sponsor
-
Notifications
You must be signed in to change notification settings - Fork 369
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
URL Parsing Performance #1115
Comments
It's quite suprising that The I think getting rid of (The couple of days ETA still holds for |
Actually, |
Description
Ran a benchmark using the
npm create vite-plugin-ssr
starter repo on the index page. Used bombardier andnode --inspect
to generate flamegraph.Looks like URL parsing is taking up a disproportionate amount of time (~50%) and might be good low hanging fruit for a perf boost.

Noticed parseWithNewUrl is:
As a proof of concept I commented out the
try
section and just let thecatch
run 100% of the time, and assume there is no origin to return - I'm sure a real solution has more nuance, but this gave ~80% increased req/s and shaves ~40ms off avg latency:flamegraph after:

Not sure what the intent is behind the
origin
handling, so not sure what the real fix is, but curious what can be done.Thanks!
The text was updated successfully, but these errors were encountered: