en.help.ref-accesslog.html Maven / Gradle / Ivy
Show all versions of console-web-plugin Show documentation
HTTP Service
Use the HTTP Service page to specify the general access log policy for web applications.
The HTTP service provides the facilities for deploying web applications and for making deployed web applications accessible by HTTP clients, along with virtual servers, thread pools, and the Network Configuration capability.
The GlassFish Server uses the HTTP Service Access Log to enable and configure rotation for the access logs for the virtual servers. These logs are located in the domain-dir/logs/access
directory and are named as follows: virtual_server_name_access_log.
yyyyMMdd-
HHh
mmm
sss.txt
The HTTP Service page contains the following options.
- Load Defaults
-
Button to restore settings that have default values to their default values. Settings that do not have default values are not changed.
- Configuration Name
-
The name of the configuration to which the settings on this page apply. This field is read only.
- SSO
-
Identifies whether single sign-on is enabled by default for all web applications on all virtual servers on this server that are configured for the same realm. If this option is not enabled, single sign-on is disabled by default for all virtual servers, and users must authenticate separately to every application on each virtual server. You can override this setting for an individual virtual server. SSO can be can be enabled or disabled. This option is disabled by default.
- Access Logging
-
If this option is selected, access logging is enabled for all virtual server sub-elements that do not specify this property. If not selected, this option disables access logging for all virtual-server sub-elements that do not specify this property. This option is disabled by default.
- Rotation
-
If this option is selected, log file rotation is enabled. This option is enabled by default.
- Rotation Policy
-
The only available rotation policy is time
.
- Rotation Interval
-
The number of minutes between rotations of the access log. This field is valid only if the Rotation Policy is time
. The default value is 1,440 minutes (24 hours).
- Rotation Suffix
-
String value to be added to the end of the log file name after rotation. The default value is yyyy-MM-dd
.
Ensure that the rotation suffix contains enough values to create a unique suffix for every log rotation. For example, if the access log is rotated more frequently than once every day, include the time of day in the rotation suffix.
A unique suffix is required to ensure that the access log file is rotated every time that the rotation interval has elapsed. If the rotation suffix of the new access log file is the same as the rotation suffix of the existing access log file, the file is not rotated.
- Max File Count
-
The maximum number of rotated access log files that are to be kept. A negative value indicates that there is no limit to the file count. The default value is -1.
- Buffer Size
-
The size, in bytes, of the access log buffer, or a value less than or equal to 0 for unbuffered access logs. The default value is 32768.
- Write Interval
-
The number of seconds before the log will be written to the disk. The access log is written when the buffer is full or when the interval expires. If the value is less than or equal to 0, then the buffer is always written even if it is not full. This means that each time the server is accessed, the log message is stored directly to the file. The default value is 300.
- Format
-
String value that specifies what information is to be captured in the access log and the order in which it is captured. The default value is as follows:
%client.name% %auth-user-name% %datetime% %request% %status% %response.length%
The following values are available for inclusion in the format string:
%attribute.
name%
-
Logs the value (by calling its toString
method) of the request attribute with the given name
%auth-user-name%
-
Name of authorized user
%client.name%
-
Client host name
%client.dns%
-
Client DNS
%cookie.
name%
-
The value of the request cookie with the given name
%cookie.value%
-
The value of the first cookie found in the request
%datetime%
-
System date
%request%
-
Full HTTP request line
%status%
-
Status
%response.length%
-
Response content length
%header.referer%
-
Referer header
%header.user-agent%
-
User agent header
%http-method%
-
HTTP method
%http-uri%
-
HTTP URI
%query-str%
-
HTTP query string
%http-version%
-
HTTP protocol version
%header.accept%
-
Accept header
%header.date%
-
Date header
%header.if-mod-since%
-
If-Modified-Since header
%header.auth%
-
Authorization header
%header.
any%
-
Any valid HTTP header value defined in RFC 2616 (any
is also a valid header value; it is specified as a variable here)
%session.
name%
-
The value of the session attribute with the name name, or NULL-SESSION-ATTRIBUTE-
name if the named attribute does not exist in the session, or NULL-SESSION
if no session exists
%time-taken%
-
Time (in milliseconds) it took to service each request
%vs.id%
-
Virtual server ID
- Additional Properties
-
Additional properties for the HTTP Service. For a description of available properties, see Properties Specific to the HTTP Service.
Related Tasks
Related asadmin Commands
None.
Copyright © 2005, 2017, Oracle and/or its affiliates. All rights reserved. Legal Notices