Join GitHub today
GitHub is home to over 50 million developers working together to host and review code, manage projects, and build software together.
Sign upStreams: when streaming a blob as a request body, bypass SpiderMonkey #26709
Labels
Comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Follow-up on #25873
In that PR, when a
Blobis used as theBodyInitof aRequest, we get aReadableStreamfrom the blob(seeimpl Extractable for Blob), then later as part of transmitting the body over the network(seeTransmitBodyConnectHandler), we read chunks from the stream through SpiderMonkey(unless the blob has already been read into memory).There's a couple of problem with that:
So we should look into building a native stream, or perhaps no stream at all, in such a case.
The "no stream at all" might be feasible, since the data is coming from the
netcomponent, and that's also where it's going. Perhaps we can just pass around the file ID and then read it directly when transmitting the body, in a way similar to what is done when doing ascheme_fetch(seenet/fetch/method.rs)