...
Excerpt |
---|
The Thread Pools portlet provides information about threads being used by the Geronimo server. |
You can click Monitor to see statistics about maximum threads in the pool, lowest number recorded, highest number recorded, and threads in use for ConnectorThreadPool and DefaultThreadPool.
- DefaultThreadPool size denotes the maximum number of threads possible in the server.
- ConnectorThreadPool size denotes the pool size of the connector threads and is a subset of DefaultThreadPool size.
Note: Currently not all threads used by the server come from one of these thread pools. Future enhancements will enable additional server components to use these pools.
Applications which have requirements for a larger pool size may require you to increase the default values of 30 for ConnectorThreadPool and 500 for DefaultThreadPool. For example, assume that your application has two HTTP connectors that demand 100 simultaneous connections each. The ConnectorThreadPool size needs to be increased to 200 and the DefaultThreadPool size to 700.
The console allows you to monitor the utilization of the thread pools, but it does not yet allow you to configure the maximum pool size. Use the following procedure to modify the configuration.
You must always stop the server before changing config.xml. Any changes made to config.xml while the server is running will be lost. When the server stops, it writes a new copy of config.xml so it contains any configuration changes made while the server was running.
- Stop the server.
- Backup the server's <Geronimo_HOME>/var/config/config.xml file (where <Geronimo_HOME> is the installation directory) and then open the file in an editor.
- Find the <module> tag for the org.apache.geronimo.configs/rmi-naming module and insert the following <gbean> element inside the <module> element. Remember, if the <module> element you find is currently a singleton tag, you must change the trailing /> to > and add a </module> tag after your changes.
where 500 is replaced with the new pool size.Code Block XML XML borderStyle solid <gbean name="DefaultThreadPool"> <attribute name="keepAliveTime">5000</attribute> <attribute name="poolSize">500</attribute> </gbean>
- Find the <module> tag for the org.apache.geronimo.configs/transaction module and insert the following <gbean> element inside the <module> element. Remember, if the <module> element you find is currently a singleton tag, you must change the trailing /> to > and add a </module> tag after your changes.
where 30 is replaced with the new pool size.Code Block XML XML borderStyle solid <gbean name="ConnectorThreadPool"> <attribute name="keepAliveTime">5000</attribute> <attribute name="poolSize">30</attribute> </gbean>
- Save the updated config.xml.
- Start the server.
Note: ConnectorThreadPool is used in J2EE Connector Architecture (JCA), and DefaultThreadPool is used by Jetty and System database. They both have no connection with Tomcat Web connector.
Tomcat Web connector has its own thread pool for share among components. To change the settings for maximum and minimum thread numbers for Tomcat Web container, edit arrtibutes atrributes of the GBean TomcatWebConnector in the file <GERONIMO_HOME>/var/config/config.xml
.
...