java.lang.Object
io.helidon.webserver.http1.Http1LoggingConnectionListener
- All Implemented Interfaces:
DataListener<ConnectionContext>
,Http1ConnectionListener
Connection listener that logs all exchanged information.
-
Constructor Summary
ConstructorDescriptionHttp1LoggingConnectionListener
(String prefix) Create a new listener with a prefix (such assend
andrecv
). -
Method Summary
Modifier and TypeMethodDescriptionvoid
data
(ConnectionContext ctx, byte[] bytes, int offset, int length) Data received or sent.void
data
(ConnectionContext ctx, BufferData data) Data received or sent.void
headers
(ConnectionContext ctx, Headers headers) Handle headers.void
prologue
(ConnectionContext ctx, HttpPrologue prologue) Handle prologue.void
status
(ConnectionContext ctx, Status status) Handle status (server response only).
-
Constructor Details
-
Http1LoggingConnectionListener
Create a new listener with a prefix (such assend
andrecv
).- Parameters:
prefix
- prefix to use when logging, also used as a suffix of logger name, to enable separate configuration
-
-
Method Details
-
data
Description copied from interface:DataListener
Data received or sent.- Specified by:
data
in interfaceDataListener<ConnectionContext>
- Parameters:
ctx
- contextdata
- data
-
data
Description copied from interface:DataListener
Data received or sent.- Specified by:
data
in interfaceDataListener<ConnectionContext>
- Parameters:
ctx
- contextbytes
- byte arrayoffset
- position within the byte arraylength
- number of bytes
-
prologue
Description copied from interface:Http1ConnectionListener
Handle prologue.- Specified by:
prologue
in interfaceHttp1ConnectionListener
- Parameters:
ctx
- contextprologue
- prologue
-
headers
Description copied from interface:Http1ConnectionListener
Handle headers.- Specified by:
headers
in interfaceHttp1ConnectionListener
- Parameters:
ctx
- contextheaders
- headers
-
status
Description copied from interface:Http1ConnectionListener
Handle status (server response only).- Specified by:
status
in interfaceHttp1ConnectionListener
- Parameters:
ctx
- contextstatus
- status
-