Repository navigation
Conversation
Codecov Report❌ Patch coverage is Additional details and impacted files@@ Coverage Diff @@
## main #2713 +/- ##
==========================================
- Coverage 93.64% 91.63% -2.01%
==========================================
Files 86 90 +4
Lines 23862 24897 +1035
==========================================
+ Hits 22345 22815 +470
- Misses 1517 2082 +565 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
|
@nodejs/undici this is ready to review now, although this should not be merged until WebSocketStream is added into the spec. whatwg/websockets#48 |
|
@KhafraDev I don't have so much opinion on this one. I'm not interested in the Web API stuff. Which is why I'd like to separate them out more from undici core. If you can get one more approving review it should be mergeable. @mcollina |
|
Maybe we could start pinging the web standards team for reviews? |
| // 12. Let writable be a new WritableStream . | ||
| // 13. Set up writable with writeAlgorithm , closeAlgorithm , and abortAlgorithm . | ||
| const writable = new WritableStream({ | ||
| write: (chunk) => this.#write(chunk), |
There was a problem hiding this comment.
I don't think this is respecting backpressure.
There was a problem hiding this comment.
WritableStream should have backpressure built into it, at least according to mdn https://developer.mozilla.org/en-US/docs/Web/API/WritableStream
There was a problem hiding this comment.
Yes, but you are not forwarding the information of the underlining socket being busy up.
https://github.com/nodejs/undici/pull/2713/files#diff-c1287dec52a96e140d7231c268bfa35a6f1e0390c46ccaf15b3ba5834f2a7342R322 will return false if the socket is "full", and then emit a 'drain' event when free again. This is not connected in any way to the WritableStream.
| kReceivedClose: Symbol('received close'), | ||
| kByteParser: Symbol('byte parser') | ||
| kByteParser: Symbol('byte parser'), | ||
| kPromises: Symbol('kPromises') |
There was a problem hiding this comment.
keep the style?
| kPromises: Symbol('kPromises') | |
| kPromises: Symbol('promises') |
ae7a600 to
1abf223
Compare
enumerable implement some more implement close finish open run WPTs update wpts and fix 9/19 failures fix most remaining failures fix remaining test failures fix writing fix: implement writing completely fixup fixup
1abf223 to
13187d0
Compare
https://whatpr.org/websockets/48/7b748d3...7b81f79.html#the-websocketstream-interface
Now that the spec has been written, it's time to add it.