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
First, thank you @Ne-Lexa for this amazing library!
I'm trying to implement your library on my Nextcloud server (running as a Docker container on my Synology NAS) but when I trigger your lib, it takes too much time to actually start the download and I ended up by having a 502 bad gateway (timeout) session from nginx, especially with big files (>4GB). In my case, it's not possible to change that timeout because of Cloudflare proxy (free account).
I want to use your lib mostly because of the password feature that is not available on Nextcloud's PHP ZipStreamer but I'm trying to make it work with the basics first.
For context, Nextcloud uses this lib and all the main calls comes from here.
Somehow, the zip download starts instantly with ZipStreamer.
I managed to set up everything correctly using addFromStream method, and this is what I tried already. Grouping the code here:
$this->streamerInstance = new ZipFile();
$this->streamerInstance->addFromStream($stream, $internalName);
$this->streamerInstance->outputAsAttachment($this->streamFilename, 'application/zip');
$this->streamerInstance->close();
I also make sure that the stream from each file is not being close (the opposite from ZipStreamer).
I tried to change from php://temp to php://output inside outputAsAttachment method but it was not enough - seems like it was missing the mime type.
Is it possible to, somehow avoid the memory and download/stream instantly the zip by blocks, as I think it is from ZipStreamer?
Log:
Allowed memory size of 1048576000 bytes exhausted (tried to allocate 3177488512 bytes) at /nelexa/zip/src/ZipFile.php
Please let me know if it's clear enough or if you need more info. Thanks!
The text was updated successfully, but these errors were encountered:
1 - I'm using 3.3.0
2 - Understandable but I still have the same issue with 7zip cli - 502 bad gateway. How about queues? Do you have any example?
3 - Yes, I tried exactly that command
Did you get the chance to take a look at ZipSteamer lib?
First, thank you @Ne-Lexa for this amazing library!
I'm trying to implement your library on my Nextcloud server (running as a Docker container on my Synology NAS) but when I trigger your lib, it takes too much time to actually start the download and I ended up by having a 502 bad gateway (timeout) session from nginx, especially with big files (>4GB). In my case, it's not possible to change that timeout because of Cloudflare proxy (free account).
I want to use your lib mostly because of the password feature that is not available on Nextcloud's PHP ZipStreamer but I'm trying to make it work with the basics first.
For context, Nextcloud uses this lib and all the main calls comes from here.
Somehow, the zip download starts instantly with ZipStreamer.
I managed to set up everything correctly using
addFromStream
method, and this is what I tried already. Grouping the code here:I also make sure that the stream from each file is not being close (the opposite from ZipStreamer).
I tried to change from
php://temp
tophp://output
insideoutputAsAttachment
method but it was not enough - seems like it was missing the mime type.Is it possible to, somehow avoid the memory and download/stream instantly the zip by blocks, as I think it is from ZipStreamer?
Log:
Please let me know if it's clear enough or if you need more info. Thanks!
The text was updated successfully, but these errors were encountered: