Request:
...
Content-Range: bytes 27482871-41601067/41601068
...
I have tried to read the bytes from file and later to GZIP. The response looks like this:
response.setStatus(HttpServletResponse.SC_PARTIAL_CONTENT);
...
Server: GlassFish Server Open Source Edition 4.1
X-Powered-By: Servlet/3.1 JSP/2.3 (GlassFish Server Open Source Edition 4.1 Java/Oracle Corporation/1.8)
Date: Thu, 26 Nov 2015 21:44:21 GMT
Accept-Ranges: bytes
Connection: keep-alive
Keep-Alive: timeout=1800
Content-Disposition: attachment;filename*=utf-8''Marq_Aurel_Rayman_Rave_-_Intdo_The_Blue_%28Max_R_remix%29.wav
ETag: Marq_Aurel_Rayman_Rave_-_Intdo_The_Blue_%28Max_R_remix%29.wav-41601068-1403655006000
Cache-Control: private,max-age=604800
Last-Modified: Wed, 25 Jun 2014 00:10:06 GMT
Content-Range: bytes 27482871-41601067/41601068
Content-Encoding: gzip
...
And the download fails if I pause and resume it. Maybe I should never use GZIP in range response?