RFC - Provide true node streams
See original GitHub issueAfter investigating the pause / resume functionality for our existing Request
objects, I looked into what it would take to turn them into bonafide streams instead of a semi-ducktyped stream.
Current issues
At the moment the Request
class is quite complicated and has sprinklings of if (this.stream)
throughout and I feel we could greatly simplify the core logic by moving to a “stream first” implementation where Request
s could be promisified on demand.
The Requests from tedious are essentially streams, so this would allow us to interface with them in a more straightforward fashion.
The current stream implementation we have doesn’t work particularly well if you also want to make use of the promise functionality, so we need to clear up that usage a bit more too.
Changes required
- Request object extends
stream.Readable
- Stream operates in object mode
- Add promise transformation method to
Request
Impact
- Deprecation of
row
event and replaced withdata
event (generally conform to the Stream interface) - Requests will not be promises by default
Challenges
- Error handling
msnodesqlv8
doesn’t support resume/pause of requests
Issue Analytics
- State:
- Created 5 years ago
- Comments:15 (1 by maintainers)
Top Results From Across the Web
Operational Considerations for Streaming Media RFC 9317
This document uses these terms to describe the streaming media ecosystem: Streaming Media Operator: an entity that provides streaming media servers Media ...
Read more >RFC 4960: Stream Control Transmission Protocol
1. Handle Stream Parameters In the INIT and INIT ACK chunks, the sender of the chunk MUST indicate the number of outbound streams...
Read more >TLS (SSL) | Node.js v19.3.0 Documentation
The node:tls module provides an implementation of the Transport Layer ... it is of critical importance to use sufficient entropy as discussed in...
Read more >Call SAP RFC Function Modules from AWS Lambda using the ...
SAP provides the NW RFC SDK as C++-libraries. For Node.js (or other runtime environments) to use it, those libraries need to first be...
Read more >YAML Ain't Markup Language (YAML™) revision 1.2.2
Typically, most tags are not explicitly specified in the character stream. During parsing, nodes lacking an explicit tag are given a non- ...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Can you please add information to the docs that this is not a real stream and it is just some custom “request”? Because I thought it is the usual nodejs stream (it actually has the same methods like pause, resume and some events) and have wasted few days debugging my app.
this was fixed in #1078