1. Web Engine Properties
All properties provided by Web engines apply not only to the JVM system but also to virtual hosts and web applications. For more information about how to apply the properties, refer to Configuring Virtual Hosts, jeus-web-dd.xml Configuration in JEUS Web Engine Guide.
It is recommended to configure web engine properties at the virtual host or Web application level rather than at the JVM system or web engine level. |
1.1. Web Engine Level Properties
The following describes the properties set at the web engine level, which can be set in domain.xml. The values set in these properties override those of jeus-web-dd.xml.
-
jeus.servlet.prevent-forcibly-threadlocal-memoryleak
Description
If a web application uses the ThreadLocal variable and does not release it, a memory leak can occur. In this case, a web engine can forcibly reset the ThreadLocal variable when the web application is reloaded, redeployed, or undeployed to prevent a memory leak. Note, if this option is used, the ThreadLocal variable, which is set by another application, is also reset.
Default
false
-
jeus.servlet.request.enableDns
Description
Option to receive a host name through DNS when invoking ServletRequest.getRemoteHost().
Default
true
-
jeus.servlet.request.url.relativePathInURL
Description
How to handle a relative path ('.' or '..') in URL.
-
not_allowed: do not allow a relative path in URL, and return the 403 Forbidden error.
-
replace: convert a relative path to an absolute path.
-
keep: do not consider a relative path.
Default
replace
-
-
jeus.servlet.useCaseInsensitiveFileSystem
Description
When using a case-insensitive file server on a case-sensitive OS, such as a Linux OS + Windows file server, the request address may not be case-sensitive, which may not work as expected. This property allows case-sensitive processing in such OS combinations, and also enables the use of the following properties that only work on Windows.
-
jeus.servlet.resource.ignore-filename-case
-
jeus.servlet.jsp.ignore-filename-case
Default
false
-
-
jeus.websocket.client.requestBufferSize
Description
Size of the buffer for requests including web socket headers when calling WebSocketContainer.connectToServer().
Default
8*1024 (Unit: byte)
-
jeus.servlet.allowUrlEncodeJsessionid
Description
Forces URL Encoding for a cookie header (JSESSIONID). This property is valid when apply-url-encoding-rule is true.
Default
false
-
jeus.servlet.validate-2_5-web-xml-changes
Description
Checks whether the web.xml file was written based on version 2.5.
Default
true
-
jeus.servlet.jsp.noPackagePrefix
Description
Option to add a package to the servlet class generated in JSP.
Default
false
1.2. JVM System Properties
The following is an option that must be set only with a JVM system property.
-
org.glassfish.web.rfc2109_cookie_names_enforced
Description
IllegalArgumentException occurs when a character not allowed in RFC2109 is entered in a cookie name. This is defined in jakarta.servlet.http.Cookie, but wasn’t properly processed in API implementation up to JEUS 6.
Default
true
1.3. Virtual Host Level Properties
The following describes the properties set at the web engine level, which can be set in domain.xml. The values set in these properties override those of jeus-web-dd.xml.
Currently, the properties for this level are under development. |
1.4. Web Application Level Properties
The following describes the web application level properties, which can be set in jeus-web-dd.xml. These properties can be used as web engine or virtual host level properties.
1.4.1. JSP or Servlet Engine Properties
The following is a list of properties that apply to each servlet or JSP engine.
-
jeus.servlet.response.header.serverInfo
Description
Option to include JEUS version information in headers.
Default
false
-
jeus.servlet.keep-original-query-string-on-forward
Description
Option to preserve the existing string in the Request object or to overwrite it with the query string when forwarding.
Default
false
-
jeus.servlet.keep-original-query-string-on-include
Description
Option to preserve the existing string in the Request object or to overwrite it with the query string when including.
Default
false
-
jeus.servlet.out.ensureContentOrder
Description
Option to maintain the content order when using response.getOutputStream(), response.getWriter(), and JspWriter(jsp out) together. They shouldn’t be used together, but instead used as one.
Default
false
-
jeus.servlet.classloader.allowServletAPI
Description
Option to load the servlet API classes.
Default
false
-
jeus.servlet.context.attribute.serialize
Description
Option to serialize ServletContext attributes when reloading Context Auto.
Default
false
-
jeus.servlet.resource.ignore-filename-case
Description
Option to use upper case and lower case letters for resource file names of ResourceServlet.
This is applicable only in Windows or when jeus.servlet.useCaseInsensitiveFileSystem is true.
Default
false
-
jeus.servlet.response.header.encoding
Description
Sets the encoding to be used in response headers.
Default
null
-
jeus.servlet.scan-servlet-container-initializers
Description
Option to use ServletContainerInitializer, which was added in Servlet 3.0.
In order to conform to the servlet standard, the scan job is executed by default, but the deployment time can increase.
Default
true
-
jeus.servlet.sortWebinfLibraries
Description
Option for sorting when loading jar files included in WEB-INF/lib .
-
name_asc: Name in ascending order.
-
name_dsc: Name in descending order.
-
time_asc: LMF of a file in ascending order.
-
time_dsc: LMF of a file in descending order.
Default
null
-
-
jeus.servlet.useMetadataCompleteDeploy
Description
From Java EE 5 onward, when a web application is deployed, it is made so that the annotations defined in Java EE search defined classes. It may take a long time to deploy since the class files included in WEB-INF/lib must be searched, in addition to the class files in WEB-INF/classes.
To not search class files, users must change the metadata-complete configuration of web.xml to "true". The metadata-complete configuration can be set to "true" by adding jeus-web-dd.xml instead of modifying web.xml included in the application.
Default
false
-
jeus.servlet.jsp.allowOnlyStandardizedMethod
Description
Allows the following 8 HTTP methods for JSP or resource requests: GET, HEAD, POST, OPTIONS, PUT, DELETE, TRACE, and CONNECT.
Default
false
-
jeus.servlet.postdataParsingForSPEC
Description
Parses application/x-www-form-urlencoded only for the POST method, according to the Servlet standard.
Default
true
-
jeus.servlet.scan-servlet-container-initializers
Description
Looks for a ServletContainerInitializer according to the Servlet 3.0 standard.
Default
true
-
jeus.servlet.response.forceChunkedResponse
Description
Forces all http response headers to be sent as transfer-encoding:chunked.
Default
false
-
jeus.servlet.tempDir
Description
Specifies a temporary directory for applications.
Default
null
-
jeus.servlet.response.header.include-content-type-charset
Description
Includes charset in the Content-Type of the response header.
Default
true
1.4.2. JSP Engine Properties
The following is a list of properties that apply only to JSP engines.
-
jeus.servlet.jsp.reload
Description
Option to support JSP reloading.
Default
true
-
jeus.servlet.jsp.precompile
Description
Option to support the JSP precompile function (a function that only compiles when calling JSP according to the precompile request parameters.)
Default
true
-
jeus.servlet.jsp.print.null.as.emptystring
Description
Option to use empty strings when displaying null.
Default
false
-
jeus.servlet.jsp.jspwriter.null
Description
Character string that replaces a null.
Default
null
-
jeus.servlet.jsp.compile.retrycount
Description
Number of recompilation attempts allowed after a new servlet fails to load.
Default
2
-
jeus.servlet.jsp.compile.delay
Description
Period JSP compilation is delayed when uploading via FTP.
jeus.jsp.compile.delay, which has the same functionality, has been removed and cannot be used in the current version.
Default
0L (Unit: ms)
-
jeus.servlet.jsp.helpReloadNativeLibrariesByCallingSystemGC
Description
Handles the JVMs whose native libraries are not properly cleaned while JSPs are being reloaded.
The native libraries are cleaned up when garbage collection (GC) is performed on the JSP class loader, so JEUS can only call System.gc() and cannot guarantee 100% GC. Therefore, a reload can fail if System.loadLibrary() is used within the JSP.
Default
false
This property value calls System.gc() and System.runFinalization(), which can degrade performance. It is not recommended to modify JSPs that use native libraries while operating the system. Instead, it is recommended to create a web application that uses the native library and dispatches it to the application. The web application, however, must not perform the Context Auto Reload or redeploy.
-
jeus.servlet.jsp.ignore-filename-case
Description
Option to use upper case and lower case letters for the JSP file name. This is applicable only in Windows or when jeus.servlet.useCaseInsensitiveFileSystem is true.
Default
false
-
jeus.servlet.jsp.assure-utf8-file-encoding-detection
Description
Treats JSP file encodings as UTP-8 even if Jasper does not recognizes it as UTP-8.
Default
false
It is recommended to define the pageEncoding tag included JSP files.
-
jeus.servlet.jsp.compile-java-source-concurrently
Description
Option to compile multiple JSP files simultaneously.
Default
false
It is used only when the JSP compiler has no issue with simultaneous compilation.
-
jeus.servlet.jsp.compileConcurrencyLevel
Description
Number of threads to use when compiling multiple JSP files simultaneously. This property is valid only when the jeus.servlet.jsp.compile-java-source-concurrently property is true.
Default
1
-
jeus.servlet.jsp.development-mode
Description
Enables the development mode for JSP in JEUS. If set to true, the tag file will be recompiled if both the jsp and tag files are modified.
Default
false
-
jeus.servlet.jsp.preventByteOrderMarkJspFileByForcedResponseEncoding
Description
If the <response-encoding><forced> setting value is not UTF-8, JSP files with BOM are not allowed. A separate exception 'BOMJspFileNotAllowedException' is thrown as an error message.
Default
false
-
jeus.servlet.jsp.ignore-self-closing
Description
Option to disable self-closing (<script …/>) when parsing an XML file. If set to true, self-closing is disabled.
Default
false
-
jeus.servlet.jsp.enforceJspRecompile
Description
Enables recompilation regardless of any changes made to JSP.
Default
false
-
jeus.servlet.jsp.jspParam.urlEncode
Description
Option to encode parameters in URL.
Default
true
1.4.3. Properties for Compatibility
JEUS conforms to servlet and JSP standards by default. However, API operations can change due to a standard interpretation error, incorrect implementation of requirements, unclear descriptions, and inconsistent descriptions in the standard documents and the API documents.
-
jeus.servlet.jsp.modern
Description
Option to use JSP engine, which is compatible with JEUS 4. Only the JSP 1.2 version is supported.
The JSP engine is deprecated, so its use is not recommended. This property will be removed from the next fix or version.
Default
true
-
jeus.servlet.jsp.compileEncoding
Description
Specifies the encoding value to use when compiling JSP. Available only when jeus.servlet.jsp.modern is set to false.
Default
null
-
jeus.servlet.request.url.allowNonStandardPercentCharacterUsage
Description
Allows use of a single '%' in a URL. According to RFC 2396, 2.4.3. Excluded US-ASCII Characters, a single '%' is a reserved word for URL escape, so it must be used in a defined format. Therefore, clients have to send it as '%25'.
Default
false
-
jeus.servlet.request.6CompatibleSetCharacterEncoding
Description
The ServletRequest.setCharacterEncoding() encoding set must only apply to Request Body.
In JEUS 6, a bug was found that allows the use of the encoding when reading Request Headers such as Query String and Cookie. Use this option when supporting applications written based on the JEUS 6 bug to avoid modifications to the application.
Default
false
-
jeus.servlet.request.useResetCharacterEncoding
Description
Used to re-encode a value that has already been encoded once using a different encoding method. In JEUS, the ServletRequest.setCharacterEncoding() method becomes disabled after getParameter() or getReader() is called, making re-encoding not possible. However, other application servers, such as WebLogic, may support this functionality. To provide compatibility for users migrating from other vendors to JEUS, this feature can be enabled.
Default
false
-
jeus.servlet.response.usePercentEncodedLocationHeaderWhenRedirect
Description
When a request originates from Internet Explorer (IE), the location header is created using the server’s encoding during redirection. However, if the encoding method of the IE request differs from the server’s default encoding, IE may fail to properly interpret the query string in the location header. To address this issue, this feature supports converting the query string to percent-encoding and rewriting it.
Default
false
-
jeus.servlet.response.defaultContentType
Description
Default value of Content-Type response headers. If this value is not NULL, response headers are set in the following cases:
when calling ServletResponse.setCharacterEncoding() or ServletResponse.setLocale() and servlet did not call ServletResponse.setContentType() explicitly. However, this operation does not conform to the servlet standard for Content-Type response headers.
Default
null
According to servlet standards, Content-Type Header cannot be included in response headers unless the servlet explicitly calls ServletResponse.setContentType(). Also, when calling ServletResponse.getContentType(), null must be returned. Although these are defined in Servlet 5.0, JEUS had not followed these rules.
For JEUS 7 Fix#1 and later, the default value is changed to null to conform to the standard. If null is not returned, change the value of this property.
-
jeus.servlet.response.applyContentLanguageProperlyWithSetLocaleAPI
Description
When ServletResponse.setLocale() is called after ServletResponse.getWriter() is called, Content-Language response headers must be set. Character encoding is not changed. If Content-Language is specified incorrectly and must be invalidated, set this option to false.
Default
true
-
jeus.servlet.response.6CompatibleForcedEncoding
Description
Forces the priority of <response-encoding><forced>, which is being applied, to follow JEUS 6 operation rules. Generally, a forced option has the highest priority. This property has a higher priority than the JSP file page tag contentType or the HTTP response encoding set through the application API.
Default
false
-
jeus.servlet.response.6CompatibleSetCharacterEncoding
Description
The encoding set by ServletResponse.setCharacterEncoding() must have a lower priority than forced options. JEUS 6 and previous versions, however, do not comply with this rule and ignore forced settings. To use any applications implemented based on JEUS 6 operation rules, set this option to true.
Although this property name is similar to that of the request version, the properties operate very differently.
Default
false
-
jeus.servlet.response.allowBothWriterAndOutputStream
Description
Option to enable the use of both "HttpServletResponse.getWriter()" and "HttpServletResponse.getOutputStream". Although different methods can be used only when reset() is called, this option allows the use of the both methods.
Default
false
-
jeus.servlet.session.invalidateBySetMaxInactiveIntervalZero
Description
It provides compatibility between "0" and invalidate.
HttpSession.setMaxInactiveInterval( int timeout ) indicates a session that does not delete values under "0" according to the specification.
However, because the description of the property in the previous specification was unclear, some users used "0" as invalidate.
The JEUS property is provided for compatibility for these users.
Default
false
-
jeus.servlet.engine.disableRequestFinishCheck
Description
A request object is valid only within a service method of a servlet or the doFilter method of a filter. If a request object that has already been handled is used, IllegalStateException occurs, according to the specification. However, since JEUS 7 and previous versions do not check whether a request object has been completed, applications that use a completed request object run normally.
This property is used for compatibility between users who use applications that use a completed request object.
Default
false
-
jeus.servlet.ignoreWebComponentFailureWhenDeploying
Description
Even if an exception occurs in the init(), Filter.init(), and ServletContextListener of the servlet registered through load-on-startup during deploy, deployment does not fail.
Default
false
-
jeus.servlet.classloader.spec23
Description
As recommended in SRV.9.7.2, classes under WEB-INF are loaded before classes that apply to the entire container.
Default
false
-
jeus.servlet.ensure.contentlength
Description
Sets the content-length to always be sent when using HTTP 1.0.
Default
false
-
jeus.servlet.query.encoding.Enabled
Description
Sets encoding to be applied to the return value of HttpServletRequest#getQueryString().
Default
false
-
jeus.servlet.request.showDefaultPortInRequestURL
Description
In JEUS 7 and prior versions, if a protocol sent a request to the default port (http: 80, https: 443), the response was created after deleting the port, but from JEUS 7 onwards, this can be set as an option.
Default
false
-
jeus.servlet.jsp.superclass
Description
For WebLogic, you can specify the inheritance structure as a jsp parameter in weblogic.xml, but JEUS uses org.apache.jasper.runtime.HttpJspBase, which can be modified as a system property, but cannot be changed at the application level. This option is provided so that the setting can be changed at the application level.
Default
org.apache.jasper.runtime.HttpJspBase
-
jeus.servlet.jsp.removeJspClassPathExceptContextPath
Description
A bug was identified that caused JSP compilation to take a long time in the EJB shared state. The primary cause is presumed to be the time-consuming operation of retrieving the classpath. To address this issue, it was determined that compilation can proceed using only the ejb.jar file implemented by the user. As a solution, this option is provided to remove the classpath during the compilation process, thereby reducing the time required.
Default
null
-
jeus.servlet.jsp.addJspClassPath
Description
A bug was identified that caused JSP compilation to take a long time in the EJB shared state. The primary cause is presumed to be the time-consuming operation of retrieving the classpath. To address this issue, it was determined that compilation can proceed using only the ejb.jar file implemented by the user. As a solution, this option is provided to remove the classpath during the compilation process, thereby reducing the time required. When using this option, you need to specify the full path.
Default
null
-
jeus.servlet.jsp.taglib.scanTldExceptWEBINF
Description
If you include an excessive amount of files in WEB-INF, Tld scanning may take too long or may even result in StackOverflowError. This option is provided to skip scanning the WEB-INF folder.
Default
false
-
jeus.servlet.response.sendRedirect.useRelativeRedirects
Description
When referring to RFC7231, it appears that the location header has been changed to allow relative paths in addition to absolute paths, but the servlet spec states that absolute paths must be used. Therefore, this option is provided to allow relative paths as well.
Default
false
-
jeus.servlet.response.sendError.forceFlushBufferWhenInternalServerError
Description
Provides an option to forcefully flush the contents of the buffer when a 500 Internal Server Error occurs during writing operations using outputstream or writer.
Default
false
-
jeus.servlet.request.reuseInputStreamAfterGetParameter
Description
The servlet specification prohibits reading an inputStream more than once. However, users migrating from other vendors to JEUS may encounter compatibility issues. This option is provided to ensure seamless compatibility.
Default
false
-
jeus.servlet.request.parameter.UnescapeJavascriptEscapedParameter
Description
Provides resin and encoding compatibility options. Note that this violates the specification.
Default
false
-
jeus.servlet.request.allowContentLengthAndTransferEncodingSimultaneously
Description
JEUS detects potential HTTP request smuggling attacks when the Transfer-Encoding header and Content-Length header are received simultaneously or when multiple Content-Length headers are present. In such cases, it blocks all related requests. However, due to ambiguities in RFC7230, this option allows JEUS to treat these scenarios as non-malicious and avoid blocking requests, even if both headers are received simultaneously.
Default
false
-
jeus.servlet.makeThreadDumpBoundarySize
Description
Prints a dump when the number of threads currently running on the server exceeds the specified value.
Default
0
-
jeus.servlet.makeThreadDumpRestartCount
Description
Specifies that a restart will be attempted when the restart count, as tracked by the thread monitor, exceeds the configured threshold.
Default
0
-
jeus.servlet.makeThreadDumpRestartWithoutNodemanager
Description
Enables the system to shut down without nodemanager.
Default
false
-
jeus.servlet.makeThreadDumpMonitoringInterval
Description
Specifies the interval at which the thread monitor checks the jeus.servlet.makeThreadDumpBoundarySize value.
Default
0
-
jeus.servlet.makeThreadDumpIntervalSecond
Description
Prints a thread dump by checking the jeus.servlet.makeThreadDumpBoundarySize value before starting a new thread, in addition to the thread monitor.
Default
300
-
jeus.servlet.loader.ignoreAutoReloadAfterHotSwapFailed
Description
In earlier versions of JEUS, enabling the JEUS Hot Swap option caused an automatic reload of the entire context if even a single class failed. This behavior is now configurable and provided as an option.
Default
false
-
jeus.servlet.ignoreUserInfoInRequestURI
Description
According to RFC7230, requests containing user information in the URI should be treated as errors. In earlier versions of JEUS, such URIs were processed as regular request URIs without error handling. This behavior has been updated to generate an error when user information is present in the URI. For compatibility, an option is provided to disable this error generation, allowing user information in the URI to be processed without triggering an error.
Default
false
-
jeus.servlet.engine.waitForWorkerDestroy
Description
An issue exists where an OS-level error occurs in the built-in WebtoB when local-shutdown is called, and the worker thread does not wait for a SocketTimeoutException. This issue is planned to be fixed in a future update. In the meantime, this option is provided to enable normal operation during the implementation stage.
Default
true