Closed phazei closed 9 years ago
See #33
I need to look into this issue further, probably this weekend.
There's absolutely a bug where too much output from the childProcess causes it to crash.
The issue doesn't exist when I'm not using gulp-run, so it's somewhere in here, but since spawn is being used, maxBuffer shouldn't be the cause. I did find it doesn't crash with childProcess.exec and a large maxBuffer and doesn't crash using childProcess.spawn by itself, spawn does seem more flexible. I'd suggest reverting #33. Sorry about that.
Edit: updated info
Found an issue that kept coming up after server was running a few hours. Server has a heartbeat that outputs to stdout every 5 seconds. After a few hours the buffer fills up. Once that happens, the child process crashes. There are two issue with here.
First, when the server crashes, somewhere it's being caught and there's no message or anything. The server just stops, still running. The child process was the only thing left, so it should all die. There's no way to see the error. It took days to discover what was stopping.
Second, there's no setting to increase the maxBuffer. The default size is 200 * 1024 which is really small and there are many long running processes that might need something more customizable.