I want to stream data through an external method.
27 Apr
1999
27 Apr
'99
8:37 a.m.
What I have is several large files for downloading that I don't want to put inside BoboPOS as importing them seems to take forever. It is also more convienient if they exist outside the OODB. So what I want to do is for the user to dl the file through Zope. I have the following external method that works def serveFile(self, file, RESPONSE): RESPONSE.setHeader('Content-type', 'application/x-msdownload') dl_name = "C:/Provision/downloads/"+file dl_file = open(dl_name,'rb') retval = dl_file.read() dl_file.close() return retval However I think this is quite inefficient and will probably not work when large number of users attempt to download the same file at the same time. Anyone have a better solution?
9840
Age (days ago)
9840
Last active (days ago)
0 comments
1 participants
participants (1)
-
Jay, Dylan