Top Description Methods
reactor.netty5.http.server.logging

public Interface AccessLogArgProvider

Known Direct Implementers
reactor.netty5.http.server.logging.AbstractAccessLogArgProvider
Imports
io.netty5.handler.codec.http.headers.HttpCookiePair, reactor.util.annotation.Nullable, java.net.SocketAddress, java.time.ZonedDateTime, java.util.Map, .Set

A provider of the args required for access log.
Author
limaoning
Since
1.0.1

Method Summary

Modifier and TypeMethod and Description
public ZonedDateTime

Returns:

zoned date-time
accessDateTime
()

Returns the date-time of the moment when the request was received

public long

Returns:

the response content length
contentLength
()

Returns the response content length.

public Map<CharSequence, Set<HttpCookiePair>>

Returns:

Resolved HTTP cookies
cookies
()

Returns resolved HTTP cookies.

public long

Returns:

the request/response duration in milliseconds
duration
()

Returns the request/response duration.

public CharSequence

Returns:

the name of this method
method
()

Returns the name of this method, (e.g. "GET").

public String

Returns:

the protocol version
protocol
()

Returns the protocol version, (e.g. "HTTP/1.1" or "HTTP/2.0").

public SocketAddress

Returns:

the peer's address
remoteAddress
()

Returns the address of the remote peer or null in case of Unix Domain Sockets.

public CharSequence

Returns:

the value of the request header
requestHeader
(CharSequence
the request header name
name
)

Returns the value of a request header with the specified name or null is case such request header does not exist.

public CharSequence

Returns:

the value of the response header
responseHeader
(CharSequence
the response header name
name
)

Returns the value of a response header with the specified name or null is case such response header does not exist.

public CharSequence

Returns:

the response status
status
()

Returns the response status, (e.g. 200).

public CharSequence

Returns:

the requested URI
uri
()

Returns the requested URI, (e.g. "/hello").

public String

Returns:

the user identifier
user
()

Returns the user identifier.

Method Detail

accessDateTimeback to summary
public ZonedDateTime accessDateTime()

Returns the date-time of the moment when the request was received

Returns:ZonedDateTime

zoned date-time

Annotations
@Nullable
Since
1.0.6
contentLengthback to summary
public long contentLength()

Returns the response content length.

Returns:long

the response content length

cookiesback to summary
public Map<CharSequence, Set<HttpCookiePair>> cookies()

Returns resolved HTTP cookies.

Warning

Be cautious with cookies information and what kind of sensitive data is written to the logs. By default, no cookies information is written to the access log.

Returns:Map<CharSequence, Set<HttpCookiePair>>

Resolved HTTP cookies

Annotations
@Nullable
Since
1.0.6
durationback to summary
public long duration()

Returns the request/response duration.

Returns:long

the request/response duration in milliseconds

methodback to summary
public CharSequence method()

Returns the name of this method, (e.g. "GET").

Returns:CharSequence

the name of this method

Annotations
@Nullable
protocolback to summary
public String protocol()

Returns the protocol version, (e.g. "HTTP/1.1" or "HTTP/2.0").

Returns:String

the protocol version

Annotations
@Nullable
remoteAddressback to summary
public SocketAddress remoteAddress()

Returns the address of the remote peer or null in case of Unix Domain Sockets.

Returns:SocketAddress

the peer's address

Annotations
@Nullable
requestHeaderback to summary
public CharSequence requestHeader(CharSequence name)

Returns the value of a request header with the specified name or null is case such request header does not exist.

Parameters
name:CharSequence

the request header name

Returns:CharSequence

the value of the request header

Annotations
@Nullable
responseHeaderback to summary
public CharSequence responseHeader(CharSequence name)

Returns the value of a response header with the specified name or null is case such response header does not exist.

Parameters
name:CharSequence

the response header name

Returns:CharSequence

the value of the response header

Annotations
@Nullable
Since
1.0.4
statusback to summary
public CharSequence status()

Returns the response status, (e.g. 200).

Returns:CharSequence

the response status

Annotations
@Nullable
uriback to summary
public CharSequence uri()

Returns the requested URI, (e.g. "/hello").

Returns:CharSequence

the requested URI

Annotations
@Nullable
userback to summary
public String user()

Returns the user identifier.

Returns:String

the user identifier

Annotations
@Nullable