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"/>