: Add IWorkerSetup runtime plumbing (#2123) - #2123
Open
tmikov wants to merge 2 commits into
Open
Conversation
|
@tmikov has exported this pull request. If you are a Meta employee, you can view the originating Diff in D114374137. |
added 2 commits
August 2, 2026 17:56
Summary:
Add the design spec and the task-by-task implementation plan for
extending the Worker constructor to accept a URL, loaded via an
integrator-provided IWorkerSetup (jsi::ICast-based for
ABI-stable extension) that resolves a URL to a jsi::Buffer of script
bytes (bytecode or source), enabling zero-copy / memory-mapped native
loading, plus hooks to configure the worker RuntimeConfig and run
one-time JS setup in the worker runtime. Also covers string-vs-URL
classification with {inline} and opt-in {allowData} data: URL
decoding, URL-object ToString coercion, and the relationship to the
standard Blob/createObjectURL web idiom (host-level, composed on top of
the resolver). Documentation only.
Reviewed By: avp
Differential Revision: D114087763
Summary: Add IWorkerSetup and ISetWorkerSetup to hermes-interfaces.h (an ICast-based setter with a getWorkerSetup accessor), and wire HermesRuntimeImpl to store the integrator's opaque provider pointer and expose it via that getter. Give the APITest provider harness a virtual destructor and mark a not-yet-used helper [[maybe_unused]] so the build is warning-free. Changelog: Add IWorkerSetup Differential Revision: D114374137
tmikov
force-pushed
the
export-D114374137
branch
from
August 3, 2026 00:57
d6f1119 to
886c03c
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary:
Add IWorkerSetup and ISetWorkerSetup to
hermes-interfaces.h (an ICast-based setter with a
getWorkerSetup accessor), and wire HermesRuntimeImpl to store
the integrator's opaque provider pointer and expose it via that getter.
Give the APITest provider harness a virtual destructor and mark a
not-yet-used helper [[maybe_unused]] so the build is warning-free.
Changelog: Add IWorkerSetup
Differential Revision: D114374137