Why is my MultipartFile is empty
<p>I passed the file convert to <code>MultipartFile</code>, but the <code>MultipartFile</code> is empty, please help to confirm it, thank you very much,
Code as follows:</p>

<pre><code>File file = new File("/Users/aikaliu/document/micrown/source/img/20160802144001791.jpg");
    int fileSize =Integer.parseInt(file.length() + "");

    DiskFileItem fileItem = null;
    try {
        fileItem = new DiskFileItem("file", "text/plain", false, file.getName(),fileSize, file.getParentFile());
        fileItem.getOutputStream();
    } catch (IOException e) {
        e.printStackTrace();
    }

    MultipartFile multipartFile = new CommonsMultipartFile(fileItem);
</code></pre>