Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit 53ad91c

Browse filesBrowse files
mcollinaFishrock123
authored andcommitted
doc,stream: _transform happens one at a time
Add a note to the stream docs specifying that at most a single call to _transform can happen, and the provided callback() should be used to process another chunk. Fixes: #3208 PR-URL: #14321 Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Rich Trott <rtrott@gmail.com> Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com> Reviewed-By: Luigi Pinca <luigipinca@gmail.com> Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
1 parent 72febfd commit 53ad91c
Copy full SHA for 53ad91c

File tree

Expand file treeCollapse file tree

1 file changed

+4
-0
lines changed
Open diff view settings
Filter options
Expand file treeCollapse file tree

1 file changed

+4
-0
lines changed
Open diff view settings
Collapse file

‎doc/api/stream.md‎

Copy file name to clipboardExpand all lines: doc/api/stream.md
+4Lines changed: 4 additions & 0 deletions
  • Display the source diff
  • Display the rich diff
Original file line numberDiff line numberDiff line change
@@ -2033,6 +2033,10 @@ The `transform._transform()` method is prefixed with an underscore because it
20332033
is internal to the class that defines it, and should never be called directly by
20342034
user programs.
20352035

2036+
`transform._transform()` is never called in parallel; streams implement a
2037+
queue mechanism, and to receive the next chunk, `callback` must be
2038+
called, either synchronously or asychronously.
2039+
20362040
#### Class: stream.PassThrough
20372041

20382042
The `stream.PassThrough` class is a trivial implementation of a [Transform][]

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.