scalajettyjetty-9scalatra

sending large files with scalatra server ends after 2^31 - 1 bytes


We are using scalatra with Jetty 9. We are have an endpoint which serves static files. But I've noticed that anything that is greater than 2GB seems to get truncated. I can see that the file gets sent chunked. Curl and wget can properly start the download and they finish without an error. I've looked for issues with scalatra and Jetty and haven't seen anything like the issue I'm seeing. But it looks like someone used an int when they needed a long


Solution

  • This is fixed in scalatra 2.5.0+ http://scalatra.org/2016/11/21/2016-11-21-scalatra-2-5-released.html