qax-os / excelize

Go language library for reading and writing Microsoft Excel™ (XLAM / XLSM / XLSX / XLTM / XLTX) spreadsheets
https://xuri.me/excelize
BSD 3-Clause "New" or "Revised" License
17.98k stars 1.71k forks source link

how real stream work? #1973

Closed code-innovator-zyx closed 3 weeks ago

code-innovator-zyx commented 3 weeks ago

Is it possible to use SAX mode to process the file, so that we can realize the true meaning of streaming data, the current streaming once exported millions of data, the memory will be unimaginable. The real meaning of streaming is that no matter how much data you export, its memory is within your control!

xuri commented 3 weeks ago

Thanks for your issue. For stream mode read, the SAX (Simple API for XML) algorithm is already used for lexing and parsing internal part of workbook in the rows iterator. The excelize also provides UnzipSizeLimit and UnzipXMLSizeLimit fields in the Options for allow you control reading resourcee usage, you can get more details from the documentation. For stream mode write, this library has its own implementation in stream writer to generate workbook. Also reference issues #753, #1052, #1429, #1739, #1782.

xuri commented 3 weeks ago

I'll close this, if you have any questions, please let me know, and you can reopen this anytime.