Repository navigation
v2.2.2
The RAR adapter read the entire file into a buffer, copied it, and had node-unrar-js extract every entry before yielding the first one so even listing entry names cost several times the archive's size in memory.
It now reads the archive from disk through node-unrar-js's file extractor. Listing only walks the entry headers and an entry is decompressed through a staging file when its stream is opened, one entry at a time. A Buffer input is written to the staging directory first.
RAR reads now use the tempDir option. Reading a single entry from a solid archive, or reading entries out of archive order, costs an extra decompression pass.