[Lispweb] Allegroserve/Webactions POST filesize limit?
Ng Pheng Siong
ngps at netmemetic.com
Wed Jul 27 08:32:23 CDT 2005
On Wed, Jul 27, 2005 at 07:12:01AM +0000, Petter Gustad wrote:
> Is there a way to limit the size of files transfered to Allegroserve?
According to the aserve manual:
(get-all-multipart-data request &key type size external-format limit)
"[...] limit can be given an integer value that specifies the maximum size
of data you're willing to retrieve. By default there is no limit. This can
be dangerous as a user may try to upload a huge data file which will take
up so much Lisp heap space that it takes down the server. If a limit is
given and that limit is reached, get-all-multipart-data will continue
to read the data from the client until it reaches the end of the data,
however it will not save it and will return the symbol :limit to indicate
that the data being sent to the server exceeded the limit. [...]
"If your application intends to handle very large amounts
of data being uploaded to the server you would be better off using
get-multipart-sequence since with that you can write the data buffer
by buffer to the disk instead of storing it in the Lisp heap."
I've used the latter in code; works as advertised in paserve.
HTH.
--
Ng Pheng Siong <ngps at netmemetic.com>
More information about the lispweb
mailing list