fixes BUG-45064: Update Apache Commons FileUpload
Update Apache Commons FileUpload library to version 1.4. Together with the library upgrade some minor changes are required:
- FileItem class is no longer serializable[1]. For this reason with the commons-fileupload update to version 1.4 we are no longer calling "setSessionObject(String attribute, Serializable value)" with FileItem as second argument but "setSessionObject(String attribute, Object value)" which is deprecated.
The problem is that with this change the session is no longer serializable after setting into it a FileItem object. For the moment no additional actions are going to be applied as this is only happening in ModuleManagement window. So we are just adding a comment and the SuppressWarnings annotation.
-
Removed unnecessary @SuppressWarnings("unchecked"). The ServletFileUpload.parseRequest method does no longer require it as now it is returning List instead of List.
-
Applied some minor code cleanup: removed commented-out code and use a logger to log the exception.