Saturday, October 10, 2015

Web Application for File Upload with streaming

This gives you an entire working example (worth 1000 user manual pages) .... I have tested it and put in (just git clone it and run it).

Here the user guide of Apache FileUpload module:

Create a webapp

Download commons-io jar and commons-fileupload jar and place them in WEB-INF/lib

Well actually rather than putting here snippets of code, here is the whole NON-Streaming example and here the STREAMING example

I have tested with a 4GB file and memory occupation on the server (and Garbage Collection) was really minimal... transfer speed was also decent (say 2 minutes for a 4GB file....).

Here you can download the war file directly.

No comments: