source: nutchez-0.1/tomcat/webapps/docs/config/executor.html @ 77

Last change on this file since 77 was 66, checked in by waue, 16 years ago

NutchEz - an easy way to nutch

File size: 8.0 KB
Line 
1<html><head><META http-equiv="Content-Type" content="text/html; charset=iso-8859-1"><title>Apache Tomcat Configuration Reference - The Executor (thread pool)</title><meta value="Filip Hanik" name="author"><meta value="fhanik@apache.org" name="email"></head><body vlink="#525D76" alink="#525D76" link="#525D76" text="#000000" bgcolor="#ffffff"><table cellspacing="0" width="100%" border="0"><!--PAGE HEADER--><tr><td><!--PROJECT LOGO--><a href="http://tomcat.apache.org/"><img border="0" alt="
2    The Apache Tomcat Servlet/JSP Container
3  " align="right" src="../images/tomcat.gif"></a></td><td><font face="arial,helvetica,sanserif"><h1>Apache Tomcat 6.0</h1></font></td><td><!--APACHE LOGO--><a href="http://www.apache.org/"><img border="0" alt="Apache Logo" align="right" src="../images/asf-logo.gif"></a></td></tr></table><table cellspacing="4" width="100%" border="0"><!--HEADER SEPARATOR--><tr><td colspan="2"><hr size="1" noshade></td></tr><tr><!--LEFT SIDE NAVIGATION--><td nowrap="true" valign="top" width="20%"><p><strong>Links</strong></p><ul><li><a href="../index.html">Docs Home</a></li><li><a href="index.html">Config Ref. Home</a></li></ul><p><strong>Top Level Elements</strong></p><ul><li><a href="server.html">Server</a></li><li><a href="service.html">Service</a></li></ul><p><strong>Executors</strong></p><ul><li><a href="executor.html">Executor</a></li></ul><p><strong>Connectors</strong></p><ul><li><a href="http.html">HTTP</a></li><li><a href="ajp.html">AJP</a></li></ul><p><strong>Containers</strong></p><ul><li><a href="context.html">Context</a></li><li><a href="engine.html">Engine</a></li><li><a href="host.html">Host</a></li><li><a href="cluster.html">Cluster</a></li></ul><p><strong>Nested Components</strong></p><ul><li><a href="globalresources.html">Global Resources</a></li><li><a href="loader.html">Loader</a></li><li><a href="manager.html">Manager</a></li><li><a href="realm.html">Realm</a></li><li><a href="resources.html">Resources</a></li><li><a href="valve.html">Valve</a></li></ul><p><strong>Cluster Elements</strong></p><ul><li><a href="cluster.html">Cluster</a></li><li><a href="cluster-manager.html">Manager</a></li><li><a href="cluster-channel.html">Channel</a></li><li><a href="cluster-membership.html">Channel/Membership</a></li><li><a href="cluster-sender.html">Channel/Sender</a></li><li><a href="cluster-receiver.html">Channel/Receiver</a></li><li><a href="cluster-interceptor.html">Channel/Interceptor</a></li><li><a href="cluster-valve.html">Valve</a></li><li><a href="cluster-deployer.html">Deployer</a></li><li><a href="cluster-listener.html">ClusterListener</a></li></ul><p><strong>Global Settings</strong></p><ul><li><a href="systemprops.html">System properties</a></li></ul></td><!--RIGHT SIDE MAIN BODY--><td align="left" valign="top" width="80%"><table cellspacing="4" width="100%" border="0"><tr><td valign="top" align="left"><h1>Apache Tomcat Configuration Reference</h1><h2>The Executor (thread pool)</h2></td><td nowrap="true" valign="top" align="right"><small><a href="printer/executor.html"><img alt="Printer Friendly Version" border="0" src="../images/printer.gif"><br>print-friendly<br>version
4                    </a></small></td></tr></table><table cellpadding="2" cellspacing="0" border="0"><tr><td bgcolor="#525D76"><font face="arial,helvetica.sanserif" color="#ffffff"><a name="Introduction"><strong>Introduction</strong></a></font></td></tr><tr><td><blockquote>
5
6  <p>The <strong>Executor</strong> represents a thread pool that can be shared
7     between components in Tomcat. Historically there has been a thread pool per
8     connector created but this allows you to share a thread pool, between (primarly) connector
9     but also other components when those get configured to support executors</p>
10
11
12  <p>The executor has to implement the <code>org.apache.catalina.Executor</code> interface.</p>
13 
14  <p>The executor is a nested element to the <a href="service.html">Service</a> element.
15     And in order for it to be picked up by the connectors, the Executor element has to appear
16     prior to the Connector element in server.xml</p>
17</blockquote></td></tr></table><table cellpadding="2" cellspacing="0" border="0"><tr><td bgcolor="#525D76"><font face="arial,helvetica.sanserif" color="#ffffff"><a name="Attributes"><strong>Attributes</strong></a></font></td></tr><tr><td><blockquote>
18
19  <table cellpadding="2" cellspacing="0" border="0"><tr><td bgcolor="#828DA6"><font face="arial,helvetica.sanserif" color="#ffffff"><a name="Common Attributes"><strong>Common Attributes</strong></a></font></td></tr><tr><td><blockquote>
20
21  <p>All implementations of <strong>Executor</strong>
22  support the following attributes:</p>
23
24  <table cellpadding="5" border="1"><tr><th bgcolor="#023264" width="15%"><font color="#ffffff">Attribute</font></th><th bgcolor="#023264" width="85%"><font color="#ffffff">Description</font></th></tr><tr><td valign="center" align="left"><code>className</code></td><td valign="center" align="left">
25      <p>The class of the implementation. The implementation has to implement the
26         <code>org.apache.catalina.Executor</code> interface.
27         This interface ensures that the object can be referenced through its <code>name</code> attribute
28         and that implements Lifecycle, so that it can be started and stopped with the container.
29         The default value for the className is <code>org.apache.catalina.core.StandardThreadExecutor</code></p>
30    </td></tr><tr><td valign="center" align="left"><strong><code>name</code></strong></td><td valign="center" align="left">
31      <p>The name used to reference this pool in other places in server.xml.
32         The name is required and must be unique.</p>
33    </td></tr></table>
34
35  </blockquote></td></tr></table>
36
37  <table cellpadding="2" cellspacing="0" border="0"><tr><td bgcolor="#828DA6"><font face="arial,helvetica.sanserif" color="#ffffff"><a name="Standard Implementation"><strong>Standard Implementation</strong></a></font></td></tr><tr><td><blockquote>
38
39  <p>
40  The default implementation supports the following attributes:</p>
41
42  <table cellpadding="5" border="1"><tr><th bgcolor="#023264" width="15%"><font color="#ffffff">Attribute</font></th><th bgcolor="#023264" width="85%"><font color="#ffffff">Description</font></th></tr><tr><td valign="center" align="left"><code>threadPriority</code></td><td valign="center" align="left">
43      <p>(int) The thread priority for threads in the executor, the default is <code>Thread.NORM_PRIORITY</code></p>
44    </td></tr><tr><td valign="center" align="left"><code>daemon</code></td><td valign="center" align="left">
45      <p>(boolean) Whether the threads should be daemon threads or not, the default is <code>true</code></p>
46    </td></tr><tr><td valign="center" align="left"><code>namePrefix</code></td><td valign="center" align="left">
47      <p>(String) The name prefix for each thread created by the executor.
48         The thread name for an individual thread will be <code>namePrefix+threadNumber</code></p>
49    </td></tr><tr><td valign="center" align="left"><code>maxThreads</code></td><td valign="center" align="left">
50      <p>(int) The max number of active threads in this pool, default is <code>200</code></p>
51    </td></tr><tr><td valign="center" align="left"><code>minSpareThreads</code></td><td valign="center" align="left">
52      <p>(int) The minimum number of threads always kept alive, default is <code>25</code></p>
53    </td></tr><tr><td valign="center" align="left"><code>maxIdleTime</code></td><td valign="center" align="left">
54      <p>(int) The number of milliseconds before an idle thread shutsdown, unless the number of active threads are less
55         or equal to minSpareThreads. Default value is <code>60000</code>(1 minute)</p>
56    </td></tr></table>
57
58
59  </blockquote></td></tr></table>
60</blockquote></td></tr></table></td></tr><!--FOOTER SEPARATOR--><tr><td colspan="2"><hr size="1" noshade></td></tr><!--PAGE FOOTER--><tr><td colspan="2"><div align="center"><font size="-1" color="#525D76"><em>
61        Copyright &copy; 1999-2008, Apache Software Foundation
62        </em></font></div></td></tr></table></body></html>
Note: See TracBrowser for help on using the repository browser.