Summary: | Split large document multiple small document | ||
---|---|---|---|
Product: | POI | Reporter: | Dilipkumar <dkaruppan> |
Component: | XWPF | Assignee: | POI Developers List <dev> |
Status: | RESOLVED INVALID | ||
Severity: | blocker | ||
Priority: | P2 | ||
Version: | unspecified | ||
Target Milestone: | --- | ||
Hardware: | PC | ||
OS: | All | ||
Attachments: | WHile converting large docx file into sfdt format throwing error |
Apologies Dilip - this is a bug tracker and this is not a bug. I would suggest you use stackoverflow or possibly the POI user email list. Have you tried increasing the heap size on your JVM? (-Xmx) Maybe also worth reading articles like https://stackoverflow.com/questions/45740269/parsing-large-docx-file-in-java |
Created attachment 37539 [details] WHile converting large docx file into sfdt format throwing error HI I am converting docx into sfdt fromat it is worked for fine with 150 document having 200 pages if documents large file which contains 2500 pages (8 mb) file means it giving error out of memory error.Can any one help how to resolve this error or suggest me solution to split large document into multiple small documents.I have attached error also kindly check and make quick response on that. this is the exact code i am using. @PostMapping("/wordeditor/Import") public String uploadFile(@RequestParam("files") MultipartFile file) throws Exception { try { return WordProcessorHelper.load(file.getInputStream(), FormatType.Docx); } catch (Exception e) { e.printStackTrace(); return "{\"sections\":[{\"blocks\":[{\"inlines\":[{\"text\":" + e.getMessage() + "}]}]}]}"; } }