Reproducible hang in busboy
See original GitHub issueI’ve been investigating an occasional hang in our application, and tracked it down to what appears to be a busboy issue. There is a test case (client and server) in this repository. See the README in that repository for instructions and some discussion. A couple of key points from there:
- The problem only seems to occur when using the
.pipe()
method of the file object. Listening fordata
andend
events works as expected, without hanging. - It seems to depend on how the request is split across TCP/IP packets. Sending the terminator string in the same chunk as the final field also makes it work without hanging.
Issues of this sort seem to have been reported before (e.g. #116, mscdex/connect-busboy#15; probably others) without any resolution being reached. I hope having a simple test case will make it easier to find the root cause.
Issue Analytics
- State:
- Created 5 years ago
- Reactions:2
- Comments:11 (3 by maintainers)
Top Results From Across the Web
node.js - Busboy hangs (in express.js) - Stack Overflow
Ok, I found the reason why it hanged. I mistekaly forgot close the connection, below lines: busboy.on('finish', function() { res.
Read more >Diagnostic Test - Innovative Food Safety Solutions
Reproducible for instructional use only. Not for individual sale. page 1 of 17. Practice Tests and Answer Keys. Diagnostic Test.
Read more >Jupyter cells hang on execution. : r/vscode - Reddit
Hi, I'm having a weird problem where execution of Python code cells in the Jupyter notebook hangs constantly (maybe every second attempt ...
Read more >Nature, woman and lyrical ambiguity in Shen Congwen's writing ...
While nature connotes the cosmic and the universal, "[TEXT NOT REPRODUCIBLE IN ASCII]" (pattern, literature) is regarded as "born together with Heaven and...
Read more >Under Siege 2: Dark Territory (1995) - Quotes - IMDb
Get what I'm trying to say to you here bus boy? ... [a mercenary bungees from the train to Ryback, hanging on a...
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 FreeTop 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
Top GitHub Comments
Thanks for repro repo! I ended up at the same conclusion as you, however I made the fix in a slightly different place because a
file.push(null)
may not translate to'end'
being emitted immediately if the file stream is paused IIRC, so it may not be safe to resume parsing until we see'end'
.@mscdex thanks for the quick fix,
graphql-upload
consumers had noticed this subtle issue but we couldn’t pin it down at the time.But why is this release semver v0.3.0 instead of v0.2.15?
And could you please release v1.0.0. Consumers won’t get fixes like this without every library author manually changing their
busboy
v0.x dependency and publishing a new release: