Java gzip file download from s3






















This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode characters Show hidden characters.

Copy link. Could you tell the values for those three variables by giving example. Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment. You signed in with another tab or window. Reload to refresh your session. You signed out in another tab or window. BufferedOutputStream ;. File ;.

FileOutputStream ;. IOException ;. InputStream ;. OutputStream ;. PrintStream ;. Viewed 14k times. What should I do? Improve this question. Community Bot 1 1 1 silver badge. Why can't you ungzip it and then read it to a file?

Because fileObj is an S3Object , so I cannot use the method described in this — ylun. Have you tried getting the S3Object, wrapping it in an input data stream, wrapping that in a Gzip stream, and then writing it out to a file?

Didn't work, but I did end up solving issue, will answer qn shortly jstnchng — ylun. Add a comment. Active Oldest Votes. I solved the issue using a Scanner instead of an InputStream. Improve this answer. I had the same issue before that I fixed a week or so ago, I put it into an gzipinput stream and read from it with a buffered reader. Really, that worked for you? John Stark 1, 1 1 gold badge 8 8 silver badges 20 20 bronze badges. Will it decompress the file in memory or on s3? Sargurunathan Balasubramanian Sargurunathan Balasubramanian 11 2 2 bronze badges.

Mugdha Mugdha 1 1 silver badge 9 9 bronze badges. Moinuddin Quadri 42k 9 9 gold badges 85 85 silver badges bronze badges. Sebastian Gozin Sebastian Gozin 9 1 1 bronze badge. Sign up or log in Sign up using Google. Sign up using Facebook. Sign up using Email and Password.

Post as a guest Name. Email Required, but never shown. The Overflow Blog. Podcast An oral history of Stack Overflow — told by its founding team. Millinery on the Stack: Join us for Winter Summer?



0コメント

  • 1000 / 1000