Add ada-url dependency, initial impl of jsg::Url#1273
Conversation
irvinebroque
left a comment
There was a problem hiding this comment.
🎉 exciting! two questions
- Re: edge cases — maybe a way to run ada in an observe only mode for some period of time, for some subset of requests, log any differences in output between our current implementation and ada-url? or do we know enough with confidence to hunt these down upfront?
- Ada is fast, wonder how much faster than what we have today?
I do not plan on replacing the underlying implementation of
The current url-standard implementation was based entirely off of the original Node.js implementation. I would expect the performance improvement here to be able the same as we see from Node.js' switch to ada. |
dd19de7 to
5389d0f
Compare
|
This is currently having challenges on windows due to the simd instructions. Will need to get that figured out. |
|
I believe the SIMD problem here is the same problem we had with other code after the Github runner image upgraded to LLVM 16 – this caused bazel to include the wrong SIMD header. Orion developed a workaround and contributed a fix (bazelbuild/bazel#19391) that will be available in bazel 6.4.0. To solve the issues for this PR, you can adjust .bazelrc to modify the includes like Orion did in the workaround. 6.4.0 should be released next week though, so you can also see if that fixes things here too by testing with the release candidate as in #1277. |
b3f5a3f to
3d9e6cb
Compare
|
woo green ci! next step is to update the internal repo workspace to make sure this will compile. |
3d9e6cb to
04c7e11
Compare
|
Internal CI looks good. |
04c7e11 to
83a8827
Compare
This comment was marked as resolved.
This comment was marked as resolved.
e2eb114 to
bfa307a
Compare
|
Added basic parse tests based on the corpus of WPT url tests. These don't test all of the getters/setters on |
|
Going to wait to land this until after we also get the url search params iterator support landed up stream, that way we can convert |
bfa307a to
e1bb316
Compare
|
Ok, |
This will serve as the new underlying implementation of the
url-standard.{h|c++} class while also supporting handling of
module import specifiers as URLs.
e1bb316 to
aaf0904
Compare
|
Merging this. There's still a lot to do before we can really start using it. Just a taste:
|
This will serve as the new underlying implementation of the url-standard.{h|c++} class while also supporting handling of module import specifiers as URLs.
Why using ada-url at all? It's fast and spec compliant (verified against the web platform tests for the URL spec). And it allows us to delete a bunch of code relating to our current standard URL parser. That'll be done in a separate URL as we need to verify that switching won't break any edge cases.
/cc @anonrig