posted 17 years ago
- I am keeping a set of files in session as ByteArrayStream objects.
- Based on the user's request respective file/files is/are zipped and downloaded.
- First time I download, I am getting the file size and file correctly. But if I make a repeat filedownload request I am noticing the file size is zero bytes.
I am guessing this is bcoz the ZipOutputStream(wrapper to OutputStream)is empty as I have made request for that.
How can I make the streams available until the session expires? I would like to prevent reading the same files per request from database. Instead, I would like to read and keep them in cache.
How can I achieve this?
Thanks in advance to all the reviewers.