當試圖使用AjaxUpload導入excel文件時,使用小文件可以執行導入。隨着稍大的Excel文件組成的數據接近2MB,我得到了以下錯誤。無法上傳帶有ajaxUpload()的大型excel文件
這裏是我的ajaxUpload()內的jsp:
$.ajaxFileUpload(
{
url:'pi/importPI.do?custNamefrmList='+custNamefrmList+'&neNamefrmList='+neNamefrmList+'&bIndex='+bIndex+'+&fullPath='+fullPath+'',
type:"post",
secureuri:false,
fileElementId:'uploadfile',
method:'POST',
//dataType: 'json',
dataType: 'json',
cache:false,
async:false,
success: function (data)
{
}
2013年4月5日下午12時14分51秒org.apache.catalina.core.StandardWrapperValve調用 重度:Servlet.service()進行的servlet [dispatcher]與路徑上下文[/ PMDB]拋出異常[Request processing failed;嵌套異常是org.springframework.web.multipart.MultipartException:無法分析多部分servlet請求;嵌套的異常是org.apache.commons.fileupload.FileUploadBase $ IOFileUploadException:處理multipart/form-data請求失敗。連接復位]與根源 java.net.SocketException異常:連接復位
在java.net.SocketInputStream.read(SocketInputStream.java:168)
在org.apache.coyote.http11.InternalInputBuffer.fill(InternalInputBuffer的.java:532) 在org.apache.coyote.http11.InternalInputBuffer.fill(InternalInputBuffer.java:501) 在org.apache.coyote.http11.InternalInputBuffer $ InputStreamInputBuffer.doRead(InternalInputBuffer.java:563) 在組織.apache.coyote.http11.filters.IdentityInputFilter.doRead(IdentityInputFilter.java:118) at org.apache.coyote.http11.AbstractInputBuffer.doRead(AbstractInputBuffer.java:341) at org.apache.coyote.Reques t.doRead(Request.java:422) at org.apache.catalina.connector.InputBuffer.realReadBytes(InputBuffer.java:290) at org.apache.tomcat.util.buf.ByteChunk.substract(ByteChunk.java: 431) at org.apache.catalina.connector.InputBuffer.read(InputBuffer.java:315) at org.apache.catalina.connector.CoyoteInputStream.read(CoyoteInputStream.java:200) at org.apache.commons。文件上傳.MultipartStream $ ItemInputStream.makeAvailable(MultipartStream.java:976) at org.apache.commons.fileupload.MultipartStream $ ItemInputStream.read(MultipartStream.java:886) at java.io.InputStream.read(InputStream.java :85)
at org.apache.commons.fileupload.util.Streams.copy(Streams.java :96) 在org.apache.commons.fileupload.util.Streams.copy(Streams.java:66) 在org.apache.commons.fileupload.FileUploadBase.parseRequest(FileUploadBase.java:366) 在org.apache .commons.fileupload.servlet.ServletFileUpload.parseRequest(ServletFileUpload.java:126) at org.springframework.web.multipart.commons.CommonsMultipartResolver.parseRequest(CommonsMultipartResolver.java:155) at org.springframework.web.multipart.commons .CommonsMultipartResolver.resolveMultipart(CommonsMultipartResolver.java:138) 在org.springframework.web.servlet.DispatcherServlet.checkMultipart(DispatcherServlet.java:904) 在org.springframework.web.servlet.DispatcherServlet.doDispatch(DispatcherServlet.java:747 ) at org.springframework.web.servlet.DispatcherServ let.doService(DispatcherServlet.java:716) at org.springframework.web.servlet.FrameworkServlet.processRequest(FrameworkServlet.java:644) at org.springframework.web.servlet.FrameworkServlet.doPost(FrameworkServlet.java:560) 在javax.servlet.http.HttpServlet.service(HttpServlet.java:641) 在javax.servlet.http.HttpServlet.service(HttpServlet.java:722) 在org.apache.catalina.core.ApplicationFilterChain.internalDoFilter( ApplicationFilterChain.java:305) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:210) at org.netbeans.modules.web.monitor.server。MonitorFilter.doFilter(MonitorFilter.java:393) 在org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:243) 在org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:210) 在org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:225) 在org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:169) 在org.apache.catalina.authenticator。 AuthenticatorBase.invoke(AuthenticatorBase.java:472) at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:168) at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:98) at org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.jav一:927) 在org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:118) 在org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:407) 在org.apache。 coyote.http11.AbstractHttp11Processor.process(AbstractHttp11Processor.java:999) at org.apache.coyote.AbstractProtocol $ AbstractConnectionHandler.process(AbstractProtocol.java:565) at org.apache.tomcat.util.net.JIoEndpoint $ SocketProcessor。運行(JIoEndpoint.java:309) at java.util.concurrent.ThreadPoolExecutor $ Worker.runTask(ThreadPoolExecutor.java:886) at java.util.concurrent.ThreadPoolExecutor $ Worker.run(ThreadPoolExecutor.java:908) at java.lang.Thread.run(Thread.java:662)
那麼,它不會對任何大的文件,或者只是大的Excel文件的工作問題? – nnnnnn 2013-04-05 07:32:56