Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

OptimizedGZIPInputStream fails on chunked stream #42

Open
massimo-coluzzi opened this issue Jan 12, 2017 · 2 comments
Open

OptimizedGZIPInputStream fails on chunked stream #42

massimo-coluzzi opened this issue Jan 12, 2017 · 2 comments

Comments

@massimo-coluzzi
Copy link

Hi,

we are using your library since 3 years and we think you have done a great job.
Recently we need to download a file in gzip format from a remote server.
The file is quite big so the server uses the transfer-encoding: chunked mechanism.
We download the file and save it in a temporary directory, then we unzip it.
If we use the java.util.zip.GZIPInputStream everything works fine and we get the whole file unzipped.
But if we use your com.ning.compress.gzip.OptimizedGZIPInputStream implementation we get only the first chunk unzipped.
It would be great if you could fix this issue so we can keep using your implementation.

Thanks
Massimo

@cowtowncoder
Copy link
Contributor

@massimo-coluzzi I would love to fix the problem, but for that I would need a problem reproduction: description is useful but not sufficient in repeating the problem and verifying it is fixed. So if you can provide that I can probably help.

@massimo-coluzzi
Copy link
Author

Hi,
I will attach the file mentioned in my previous message.
There are 2 versions of the file, the one downloaded with the transfer-encoding: chunked and the one not chunked. As you can see the two files have different size but the unzipped content is the same.
If you try to unzip the chunked file with java.util.zip.GZIPInputStream you will get the whole content while if you use com.ning.compress.gzip.OptimizedGZIPInputStream you will get only the first chunk.

Thanks
Massimo
chunked-feed.csv.gz
unchunked-feed.csv.gz

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants