mirror of
https://github.com/DSpace/DSpace.git
synced 2025-10-17 15:03:18 +00:00
Fix to avoid connection pool exhaustion for slow downloads and big files
This commit is contained in:
@@ -218,6 +218,9 @@ public class BitstreamServlet extends DSpaceServlet
|
||||
UIUtil.setBitstreamDisposition(bitstream.getName(), request, response);
|
||||
}
|
||||
|
||||
//DO NOT REMOVE IT - WE NEED TO FREE DB CONNECTION TO AVOID CONNECTION POOL EXHAUSTION FOR BIG FILES AND SLOW DOWNLOADS
|
||||
context.complete();
|
||||
|
||||
Utils.bufferedCopy(is, response.getOutputStream());
|
||||
is.close();
|
||||
response.getOutputStream().flush();
|
||||
|
Reference in New Issue
Block a user