config.io_helidon_webserver_accesslog_AccessLogConfig.adoc Maven / Gradle / Ivy
///////////////////////////////////////////////////////////////////////////////
Copyright (c) 2023 Oracle and/or its affiliates.
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
///////////////////////////////////////////////////////////////////////////////
ifndef::rootdir[:rootdir: {docdir}/..]
:description: Configuration of io.helidon.webserver.accesslog.AccessLogFeature
:keywords: helidon, config, io.helidon.webserver.accesslog.AccessLogFeature
:basic-table-intro: The table below lists the configuration keys that configure io.helidon.webserver.accesslog.AccessLogFeature
include::{rootdir}/includes/attributes.adoc[]
= AccessLogFeature (webserver.accesslog) Configuration
// tag::config[]
Type: link:{javadoc-base-url}/io.helidon.webserver.accesslog/io/helidon/webserver/accesslog/AccessLogFeature.html[io.helidon.webserver.accesslog.AccessLogFeature]
[source,text]
.Config key
----
access-log
----
This type provides the following service implementations:
- `io.helidon.webserver.spi.ServerFeatureProvider`
== Configuration options
.Optional configuration options
[cols="3,3a,2,5a"]
|===
|key |type |default value |description
|`enabled` |boolean |`true` |Whether this feature will be enabled.
@return whether enabled
|`format` |string |{nbsp} |The format for log entries (similar to the Apache `LogFormat`).
Log format elements
%h
IP address of the remote host
HostLogEntry
%l
The client identity. This is always undefined in Helidon.
UserIdLogEntry
%u
User ID as asserted by Helidon Security.
UserLogEntry
%t
The timestamp
TimestampLogEntry
%r
The request line (`"GET /favicon.ico HTTP/1.0"`)
RequestLineLogEntry
%s
The status code returned to the client
StatusLogEntry
%b
The entity size in bytes
SizeLogEntry
%D
The time taken in microseconds (start of request until last byte written)
TimeTakenLogEntry
%T
The time taken in seconds (start of request until last byte written), integer
TimeTakenLogEntry
%{header-name}i
Value of header `header-name`
HeaderLogEntry
@return format string, such as `%h %l %u %t %r %b %{Referer`i}
|`logger-name` |string |`io.helidon.webserver.AccessLog` |Name of the logger used to obtain access log logger from System#getLogger(String).
Defaults to `AccessLogFeature#DEFAULT_LOGGER_NAME`.
@return name of the logger to use
|`sockets` |string[] |{nbsp} |List of sockets to register this feature on. If empty, it would get registered on all sockets.
The logger used will have the expected logger with a suffix of the socket name.
@return socket names to register on, defaults to empty (all available sockets)
|`weight` |double |`1000.0` |Weight of the access log feature. We need to log access for anything happening on the server, so weight is high:
`io.helidon.webserver.accesslog.AccessLogFeature#WEIGHT`.
@return weight of the feature
|===
// end::config[]
© 2015 - 2025 Weber Informatics LLC | Privacy Policy