You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hi,
I'm getting errors when processing a large file, likely because it's opening a ton of %Stream.FileBinary instances in the background that each hold a handle on an actual "temporary" file, long before they may get written through a call to ExtractTo().
The %ArrayOfDataTypes interface is neat, but I think it's not very practical for large archives. A static method that just does the full process without returning a FileBinaryTar object would be just as practical for these cases. I was able to work around the issue by adding a pDest argument to ExtractStream()/ExtractFile() and copying much of the ExtractTo() code to the end of ExtractStream(), putting it instead of writing to tFile.fileData. Also needed %Save() in that case rather than just %Close(). I made too much of a mess on my way to this piece so don't have a PR right away, so maybe you'll beat me to writing this out in full ;-)
Thanks for sharing!
benjamin
The text was updated successfully, but these errors were encountered:
Ben, thanks for testing it, even in such a hard way with a large files.
I already have a fix for NAMEADD error, fixed in ZPM where it actually in use already.
That's funny, it's almost the exact same thing I tried (but yours is more elegant :-)). Still worth fixing here if you aren't planning to retire this repo.
Thanks!
Hi,
I'm getting errors when processing a large file, likely because it's opening a ton of %Stream.FileBinary instances in the background that each hold a handle on an actual "temporary" file, long before they may get written through a call to ExtractTo().
The %ArrayOfDataTypes interface is neat, but I think it's not very practical for large archives. A static method that just does the full process without returning a FileBinaryTar object would be just as practical for these cases. I was able to work around the issue by adding a pDest argument to ExtractStream()/ExtractFile() and copying much of the ExtractTo() code to the end of ExtractStream(), putting it instead of writing to tFile.fileData. Also needed %Save() in that case rather than just %Close(). I made too much of a mess on my way to this piece so don't have a PR right away, so maybe you'll beat me to writing this out in full ;-)
Thanks for sharing!
benjamin
The text was updated successfully, but these errors were encountered: