我查看了Spring CommonsMultipartResolver代码.它使用apache文件上传来解析多部分数据. CommonsMultipartResolver已将默认缓冲阈值设置为10kB,并使用DiskFileItemFactory创建FileItem.如果Stream大于10kB,则FileItem将写入磁盘.您还可以更改为存储库文件夹的位置,以存储临时上载的文件项.
Is there should be different file size limitation and total request size
limitation or file size is the only
limitation and the request is capable
of uploading 100s of files as lonng as
they are not too large.
我不知道您可以发送的多部分数据中的部件数量的最大限制或Spring CommonsMultipartResolver的限制,但因为它使用Apache FileUpload,我认为它们应该是相同的限制.我使用Apache FileUpload(没有Spring)来接收大于3GB的多部分流,它包含2个文件,20MB和3.6GB.虽然,我不能给你确切的限制,它应该能够处理几GB的流.
Doest the Spring request wrapper read the complete request and store it
in the JAVA heap memory or it store
temporaray files of it to be able to
use big quota.
正如我之前解释的那样,CommonsMultipartResolver使用Apache FileUpload. FileItem是使用DiskFileItemFactory创建的,因此FileItem暂时保存到磁盘. deafult记忆阈值是10kB.
Is the use of reading the httpservlet request in streaming would
change the size limitation than using
complete http request read at-once by
the application server.
对不起,我无法回答这个问题.流中的httpservlet请求和一次性读取http请求之间有什么不同?
What is the bottleneck of this process
– Java heap size, the quota of the filesystem on which my web-server
runs, the maximum allowed BLOB size
that the DataBase in which I am gonna
save the file alows? or Spring
internal limitations?
通用速度瓶颈可按以下顺序分类:网络ibm,BLOB限制应为2GB.
我不知道Spring的内部限制.但Apache FileUpload应该能够毫无问题地处理几GB的流.