mscdex / busboy

A streaming parser for HTML form data for node.js
MIT License
2.86k stars 213 forks source link

Control when file ends to upload (not in use) #289

Closed luispozoquerol closed 2 years ago

luispozoquerol commented 2 years ago

Maybe cause I'm too new but when I upload a single file many times (all the timse the same file) I get an error: file in use How do i control when file ends to upload and save in disk?

mscdex commented 2 years ago

I'm not quite sure what you're asking. File streams in busboy are just normal node.js Readable streams. It emits various events, including a 'close' event when there is no more data.

If you're asking how to handle concurrent write access to the same file, that's out of the scope of this project and is something you'll need to come up with a solution to on your own.