mirror of
https://github.com/RoastSlav/quickdrop.git
synced 2025-12-28 10:09:50 -06:00
added a header to disable nginx buffering for downloads
This commit is contained in:
@@ -568,6 +568,7 @@ public class FileService {
|
||||
.header(HttpHeaders.CONTENT_DISPOSITION, "attachment; filename=\"" + URLEncoder.encode(fileEntity.name, StandardCharsets.UTF_8) + "\"")
|
||||
.header(HttpHeaders.CONTENT_TYPE, "application/octet-stream")
|
||||
.header(HttpHeaders.CONTENT_LENGTH, String.valueOf(resource.contentLength()))
|
||||
.header("X-Accel-Buffering", "no")
|
||||
.body(responseBody);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user