#55481: perf: reuse one file: URL loader factory per session in net.fetch()
Requested by Charles Kerr · Slack thread
Description of Change
Manually backport #55438. See that PR for details.
CC @ckerr
One conflict in shell/common/api/electron_api_url_loader.cc: 43-x-y doesn't have ProtocolRegistry::CreateRegisteredFactory(), so the custom-protocol branch keeps 43-x-y's FindRegistered() lookup and now passes ElectronURLLoaderFactory::Create(...) straight to the new InterceptURLLoaderFactory(PendingRemote) signature. I also dropped an unrelated client_certificate_responder_delegate.h include that doesn't exist on this branch.
Checklist
- I have built and tested this change
- I have filled out the PR description
- I have reviewed and verified the changes
-
npm testpasses - tests are changed or added
- PR release notes describe the change in a way relevant to app developers, and are capitalized, punctuated, and past tense.
🤖 Generated with Claude Code
https://claude.ai/code/session_01KX1hkKsEp3xdXqeQ7utXkG
Release Notes
Notes: Improved performance of repeated net.fetch() calls for file: URLs.
Generated by Claude Code
Backport Information
Semver Impact
Semantic Versioning helps users understand the impact of updates:
- Major (X.y.z): Breaking changes that may require code modifications
- Minor (x.Y.z): New features that maintain backward compatibility
- Patch (x.y.Z): Bug fixes that don't change the API
- None: Changes that don't affect using facing parts of Electron