Description
Alexander Wilhelmer opened SPR-15955 and commented
On my example repo in branch "zero-bytes-files" i was able to reproduce a bug something to do with multipart file upload and the resulting transferTo method. I'm transferring files into temp files and i'm checking against zero byte files, so no data seems to be revceived on the netty server or its a bug in the synchronoss parser,
This test seems to be unfair, because it is starting 20 concurrent threads against the endpoint, but i was able to reproduce this bug on another setting, only with one thread and 100 iterations you are able to reproduce it. But you must host the first endpoint on a remote server. Some files will reproduce it more frequently, some files never. The concurrent threads force the test to reproduce it on localhost. You have to run the test min. five times, search for the first exception.
Tested with M3 (RC3) and SNAPSHOT(RC4) version from spring bootstrap, mainly on windows.
Exception:
2017-09-12 20:01:58.410 ERROR 10032 --- [ctor-http-nio-1] c.e.demo.controller.FileController : Error!
java.lang.RuntimeException: Zero byte file!
I'm working on a temporary remote test to show the not-threaded reproduction.
Affects: 5.0 RC3, 5.0 RC4
Reference URL: https://github.com/awilhelmer/spring5-multipart-demo/tree/zero-bytes-files
Issue Links:
- Delegating File downloads sends incomplete chunks [SPR-15949] #22194 Delegating File downloads sends incomplete chunks