Path: csiph.com!eternal-september.org!feeder.eternal-september.org!reader01.eternal-september.org!.POSTED!not-for-mail From: Andreas Leitgeb Newsgroups: comp.lang.java.programmer Subject: Re: reading zip file Date: Thu, 8 Aug 2019 17:51:21 -0000 (UTC) Organization: A noiseless patient Spider Lines: 16 Message-ID: References: <96b45a37-1ae3-49ea-b1ce-d35865af56a4@googlegroups.com> <2f44b0d0-26c2-4090-946f-83a5c097ed7b@googlegroups.com> Reply-To: avl@logic.at Injection-Date: Thu, 8 Aug 2019 17:51:21 -0000 (UTC) Injection-Info: reader02.eternal-september.org; posting-host="121fecb2b96c26875b2a57fa4179ca75"; logging-data="23871"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX1/h2PbbjrJUOz274rAmQQvy" User-Agent: slrn/1.0.3 (Linux) Cancel-Lock: sha1:BzFK2K4ybeakm1rHBYPdALIrTTA= Xref: csiph.com comp.lang.java.programmer:39089 Eric Douglas wrote: > I expect HTTP content length would give me the size of the zip file. > I want to know the total size of the files in the zip file, which is > what the updates to the progress bar would be based on. Are you serious? You'd download the 400MB zip file twice - once just for measuring, and then again for the contents? Are you sure, you cannot cache it locally on disk? Are you sure you cannot request some kind of digest first, that would just have nr of files and maybe total uncompressed size? Do you expect the download to be faster than saving the extracted files on disk?