tomcat最佳化---大資料量提交tomcat時,tomcat無法接收導致頁面無反應

來源:互聯網
上載者:User

標籤:tomcat   最佳化   maximum number of re   大資料   change this limit   

關於tomcat的一個最佳化問題:
有時候儲存大資料量的資料時,tomcat不最佳化的話,頁面會沒反應,tomcat後台並不報錯,只是提示下面內容:
警告: More than the maximum number of request parameters (GET plus POST) for a s
ingle request ([10,000]) were detected. Any parameters beyond this limit have be
en ignored. To change this limit, set the maxParameterCount attribute on the Con
nector.

如果遇到此問題,就要進行最佳化一下tomcat的接收資料容量,具體修改如下:
<Connector connectionTimeout="20000" port="8080" protocol="HTTP/1.1" redirectPort="8443" 
    maxThreads="150" compression="on" executor="tomcatThreadPool" URIEncoding="utf-8"
    compressableMimeType="text/html,text/xml,text/javascript,text/css,text/plain"
    noCompressionUserAgents="gozilla, traviata" compressionMinSize="50" maxParameterCount="1000000"/>

將這段內容替換掉tomcat->conf-->server.xml中一般是69,70,71行左右的<Connector .../>內容,重啟tomcat即可 。說明一下,maxParameterCount是起作用的內容,可根據需要自行加大,具體tomcat能接受的最大值是多少,這個還真沒考究過,不過一次100M資料量的提交應該是沒有問題的。

tomcat最佳化---大資料量提交tomcat時,tomcat無法接收導致頁面無反應

聯繫我們

該頁面正文內容均來源於網絡整理,並不代表阿里雲官方的觀點,該頁面所提到的產品和服務也與阿里云無關,如果該頁面內容對您造成了困擾,歡迎寫郵件給我們,收到郵件我們將在5個工作日內處理。

如果您發現本社區中有涉嫌抄襲的內容,歡迎發送郵件至: info-contact@alibabacloud.com 進行舉報並提供相關證據,工作人員會在 5 個工作天內聯絡您,一經查實,本站將立刻刪除涉嫌侵權內容。

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.