Tomcat connection thread pool Configuration

Source: Internet
Author: User

1st Methods: Configure Connector
Maxthreads: the maximum number of threads that Tomcat can use to process requests.
Minsparethreads: the initial number of Tomcat threads, that is, the minimum number of Idle threads.
Maxsparethreads: the maximum number of Idle threads in Tomcat. If it is exceeded, it will be disabled.
Acceptcount: when the number of threads that can be used to process requests is used, the number of requests that can be placed in the processing queue will not be processed.
<Connector Port = "8080" maxhttpheadersize = "8192" maxthreads = "150" minsparethreads = "25" maxsparethreads = "75" enablelookups = "false" redirectport = "8443" acceptcount =" 100 "connectiontimeout =" 20000 "disableuploadtimeout =" true "/>

2nd Methods: Configure executor and connector
Name: name of the thread pool
Class: The Class Name of the thread pool.
Nameprefix: The name prefix of the thread in the thread pool.
Maxthreads: Maximum number of threads in the thread pool
Minsparethreads: Minimum number of Idle threads in the thread pool
Maxidletime: when the minimum number of Idle threads is exceeded, multiple threads will wait for this length of time, and then close
Threadpriority: thread priority
<Executor name = "tomcatthreadpool" nameprefix = "req-Exec-" maxthreads = "1000" minsparethreads = "50" maxidletime = "60000"/> </P> <p> <connector Port = "8080" protocol = "HTTP/1.1" executor = "atatthreadpool"/>

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

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.