Forum OpenACS Q&A: Response to Creation and removal of on-the-fly created download files

Sorry, I should have been more clear.

If your file creation process is time consuming, then you might want to cache the results for some period of time, say 10 minutes, and then delete the stored file.  This would expecially be true if many users might be requesting that generated file.  Even if the content is user-specific, you would have to re-generate the file on a reload.

So it is a potential trade-off.  In your case, where the content is specific to the requesting user and the zip operation is fast AFAIK, the ns_atclose method is probably the easiest thing to do.