451634 DefaultServlet: useFileMappedBuffer javadoc is misleading

This commit is contained in:
Jan Bartel 2014-11-27 14:35:49 +11:00
parent a39dcd6fe5
commit a129b0bcd1
2 changed files with 25 additions and 16 deletions

View File

@ -69,6 +69,7 @@ import org.eclipse.jetty.util.resource.ResourceFactory;
/* ------------------------------------------------------------ */
/** The default servlet.
*
* This servlet, normally mapped to /, provides the handling for static
* content, OPTION and TRACE methods for the context.
* The following initParameters are supported, these can be set either
@ -123,7 +124,8 @@ import org.eclipse.jetty.util.resource.ResourceFactory;
* If set to true, it will use mapped file buffer to serve static content
* when using NIO connector. Setting this value to false means that
* a direct buffer will be used instead of a mapped file buffer.
* By default, this is set to true.
* This is set to false by default by this class, but may be overridden
* by eg webdefault.xml
*
* cacheControl If set, all static content will have this value set as the cache-control
* header.

View File

@ -11,17 +11,17 @@
<!-- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -->
<!-- The intent of this descriptor is to include jetty specific or common -->
<!-- configuration for all webapps. If a context has a webdefault.xml -->
<!-- descriptor, it is applied before the contexts own web.xml file -->
<!-- descriptor, it is applied before the context's own web.xml file -->
<!-- -->
<!-- A context may be assigned a default descriptor by: -->
<!-- + Calling WebApplicationContext.setDefaultsDescriptor -->
<!-- + Passed an arg to addWebApplications -->
<!-- A context may be assigned a default descriptor by calling -->
<!-- WebAppContext.setDefaultsDescriptor(String). -->
<!-- -->
<!-- This file is used both as the resource within the jetty.jar (which is -->
<!-- used as the default if no explicit defaults descriptor is set) and it -->
<!-- is copied to the etc directory of the Jetty distro and explicitly -->
<!-- by the jetty.xml file. -->
<!-- This file is present in the jetty-webapp.jar, and is used as the -->
<!-- defaults descriptor if no other is explicitly set on a context. -->
<!-- -->
<!-- A copy of this file is also placed into the $JETTY_HOME/etc dir of -->
<!-- the distribution, and is referenced by some of the other xml files, -->
<!-- eg the jetty-deploy.xml file. -->
<!-- ===================================================================== -->
<description>
@ -119,18 +119,16 @@
* maxCachedFiles The maximum number of files to cache
*
* useFileMappedBuffer
* If set to true, it will use mapped file buffer to serve static content
* when using NIO connector. Setting this value to false means that
* If set to true, it will use mapped file buffers to serve static content
* when using an NIO connector. Setting this value to false means that
* a direct buffer will be used instead of a mapped file buffer.
* By default, this is set to true.
* This file sets the value to true.
*
* cacheControl If set, all static content will have this value set as the cache-control
* header.
*
-->
<!-- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -->
<!-- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -->
<servlet>
<servlet-name>default</servlet-name>
<servlet-class>org.eclipse.jetty.servlet.DefaultServlet</servlet-class>
@ -323,6 +321,8 @@
<!-- ==================================================================== -->
<!-- Default session configuration -->
<!-- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -->
<session-config>
<session-timeout>30</session-timeout>
</session-config>
@ -330,7 +330,7 @@
<!-- ==================================================================== -->
<!-- Default MIME mappings -->
<!-- The default MIME mappings are provided by the mime.properties -->
<!-- resource in the org.eclipse.jetty.server.jar file. Additional or modified -->
<!-- resource in the jetty-http.jar file. Additional or modified -->
<!-- mappings may be specified here -->
<!-- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -->
<!-- UNCOMMENT TO ACTIVATE
@ -341,6 +341,8 @@
-->
<!-- ==================================================================== -->
<!-- Default welcome files -->
<!-- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -->
<welcome-file-list>
<welcome-file>index.html</welcome-file>
<welcome-file>index.htm</welcome-file>
@ -348,6 +350,8 @@
</welcome-file-list>
<!-- ==================================================================== -->
<!-- Default locale encodings -->
<!-- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -->
<locale-encoding-mapping-list>
<locale-encoding-mapping>
<locale>ar</locale>
@ -507,6 +511,9 @@
</locale-encoding-mapping>
</locale-encoding-mapping-list>
<!-- ==================================================================== -->
<!-- Disable TRACE method with security constraint -->
<!-- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -->
<security-constraint>
<web-resource-collection>
<web-resource-name>Disable TRACE</web-resource-name>