|Re: [jetty-dev] Looking for Jetty HttpClient that downloads large zip files ...|
Hi, On Wed, Sep 14, 2016 at 8:47 PM, Simone Bordet <sbordet@xxxxxxxxxxx> wrote: > For 1 GiB downloads, you want to save to a file. > I will expand the documentation. Filed https://github.com/eclipse/jetty.project/issues/929. The idea is to open a FileChannel, and for each invocation of Response.ContentListener.onContent(), you write the ByteBuffer to the FileChannel. If there is an error, you close the file and call Response.abort(). If all good, you close the file in Response.SuccessListener.onSuccess() -- Simone Bordet ---- http://cometd.org http://webtide.com Developer advice, training, services and support from the Jetty & CometD experts.
Back to the top