Skip to content
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

Byte Streams #567

Closed
1 task done
nidhijaju opened this issue Oct 29, 2020 · 11 comments
Closed
1 task done

Byte Streams #567

nidhijaju opened this issue Oct 29, 2020 · 11 comments
Assignees
Labels
Progress: review complete Resolution: satisfied The TAG is satisfied with this design Topic: Streams Any kind of stream-like feature Venue: WHATWG

Comments

@nidhijaju
Copy link

HIQaH! QaH! TAG!

I'm requesting a TAG review of byte streams.

The streams APIs provide ubiquitous, interoperable primitives for creating, composing, and consuming streams of data. For streams representing bytes, readable byte streams are an extended version of readable streams which are provided to handle bytes efficiently, in particular by minimizing copies.

Further details:

  • I have reviewed the TAG's API Design Principles
  • Relevant time constraints or deadlines: No specific deadlines.
  • The group where the work on this specification is currently being done: WHATWG
  • The group where standardization of this work is intended to be done (if current group is a community group or other incubation venue): WHATWG
  • Major unresolved issues with or opposition to this specification: N/A
  • This work is being funded by: Google

You should also know that...

N/A

We'd prefer the TAG provide feedback as (please delete all but the desired option):

🐛 open issues in our GitHub repo for each point of feedback

@atanassov
Copy link

@nidhijaju a few of us are looking at your Explainer during our breakout session today. It would be helpful to provide a bit more information so we can engage more efficiently and make progress. In particular - what are your explicit goals and non-goals of the feature? What other options have you considered when choosing the API? What is the exact API that you're proposing? Thanks.

@nidhijaju
Copy link
Author

Hi @atanassov, I have updated the explainer based on the questions you asked, so hopefully that helps provide some more clarification. Please let me know if there's anything else that you might need. Thank you!

@cynthia cynthia added the Topic: Streams Any kind of stream-like feature label Dec 8, 2020
@torgo torgo modified the milestones: 2020-12-07-week, 2021-01-11-week Dec 8, 2020
@hadleybeeman
Copy link
Member

Hi @nidhijaju. We're looking at this in a breakout session. Could you please spell out the user benefit or user needs in your explainer? (This is for the end user, rather than the developer.) For example, if it's all about making things faster, that's worth making explicit — and also specifying what 'things' you have in mind there. Many thanks!

@nidhijaju
Copy link
Author

Hi @hadleybeeman, the end-user benefit is that it will increase speed and lower memory usage for sites that take advantage of it. Specifically, sites that handle streaming binary data will see improved performance. I've also updated the explainer with this information, so hopefully that helps answer your question. Thank you!

@kenchris
Copy link

Hi @annevk and @jakearchibald - it would be great with your knowledge, feedback and potential concerns about this proposal.

@torgo
Copy link
Member

torgo commented Jan 12, 2021

Hi @nidhijaju - and happy new year! We're just picking this up again. You mentioned a couple of WHATWG threads in response to the question on multi-stakeholder feedback, however I don't see any obvious evidence of multiple implementations there. Is there for example a Mozilla standards position on this?

@annevk
Copy link
Member

annevk commented Jan 12, 2021

No concerns here. This has been part of the Streams standard for a long time and it was always part of the goals to provide performant I/O streams that integrate well with Typed Arrays. (See mozilla/standards-positions#457 and mozilla/standards-positions#464 for Mozilla's position.)

@jakearchibald
Copy link

Seconded!

@ricea
Copy link

ricea commented Jan 12, 2021

@torgo Chrome's is the first browser implementation, however there is an independent TypeScript implementation here: https://github.com/MattiasBuelens/web-streams-polyfill/tree/master/src/lib/readable-stream.

@ylafon
Copy link
Member

ylafon commented Jan 27, 2021

Not a fan of mixing higher level APIs and low-level optimisations, would prefer to have optimisation hints for the VM instead to make it more efficient, but as this API will only be used by people needing it right now...

@ylafon ylafon added Progress: propose closing we think it should be closed but are waiting on some feedback or consensus Resolution: satisfied The TAG is satisfied with this design and removed Progress: in progress labels Jan 27, 2021
@ylafon ylafon added Progress: review complete and removed Progress: propose closing we think it should be closed but are waiting on some feedback or consensus labels Jan 27, 2021
@ylafon ylafon closed this as completed Jan 27, 2021
@annevk
Copy link
Member

annevk commented Jan 27, 2021

I think it's the ~ same as why we have Array and ArrayBuffer. VMs can do a lot, but for certain performance needs they need help.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Progress: review complete Resolution: satisfied The TAG is satisfied with this design Topic: Streams Any kind of stream-like feature Venue: WHATWG
Projects
None yet
Development

No branches or pull requests