- All Known Implementing Classes:
HttpProbe.Adapter
public interface HttpProbe
Monitoring probe providing callbacks that may be invoked by Grizzly Http filters.
- Since:
- 2.0
- Author:
- Alexey Stashok
-
Nested Class Summary
Nested ClassesModifier and TypeInterfaceDescriptionstatic classHttpProbeadapter that provides no-op implementations for all interface methods allowing easy extension by the developer. -
Method Summary
Modifier and TypeMethodDescriptionvoidonContentChunkParseEvent(org.glassfish.grizzly.Connection connection, HttpContent content) Method will be called, when HTTP message content chunk gets parsed (either request or response).voidonContentChunkSerializeEvent(org.glassfish.grizzly.Connection connection, HttpContent content) Method will be called, when HTTP message content chunk is prepared to be serialized (either request or response).voidonContentEncodingParseEvent(org.glassfish.grizzly.Connection connection, HttpHeader header, org.glassfish.grizzly.Buffer buffer, ContentEncoding contentEncoding) Method will be called, whenContentEncodingwill be applied during the parsing/decoding of the certain HTTP message content chunk.voidonContentEncodingParseResultEvent(org.glassfish.grizzly.Connection connection, HttpHeader header, org.glassfish.grizzly.Buffer result, ContentEncoding contentEncoding) This method will be called after theContentEncodinghas been applied.voidonContentEncodingSerializeEvent(org.glassfish.grizzly.Connection connection, HttpHeader header, org.glassfish.grizzly.Buffer buffer, ContentEncoding contentEncoding) /** Method will be called, whenContentEncodingwill be applied during the serialization/encoding of the certain HTTP message content chunk.voidonContentEncodingSerializeResultEvent(org.glassfish.grizzly.Connection connection, HttpHeader header, org.glassfish.grizzly.Buffer result, ContentEncoding contentEncoding) Method will be called, whenContentEncodingwill be applied during the serialization/encoding of the certain HTTP message content chunk.voidonDataReceivedEvent(org.glassfish.grizzly.Connection connection, org.glassfish.grizzly.Buffer buffer) Method will be called, whenBufferwill come for processing to theHttpCodecFilter(either request or response).voidonDataSentEvent(org.glassfish.grizzly.Connection connection, org.glassfish.grizzly.Buffer buffer) Method will be called, whenBuffer, produced by theHttpCodecFilterwill be ready to go to the nextFilterin the chain and finally written on wire.voidonErrorEvent(org.glassfish.grizzly.Connection connection, HttpPacket httpPacket, Throwable error) Method will be called, when error occurs during theHttpCodecFilterprocessing.voidonHeaderParseEvent(org.glassfish.grizzly.Connection connection, HttpHeader header, int size) Method will be called, when HTTP message header gets parsed (either request or response).voidonHeaderSerializeEvent(org.glassfish.grizzly.Connection connection, HttpHeader header, org.glassfish.grizzly.Buffer buffer) Method will be called, when HTTP message header gets serialized (either request or response).voidonTransferEncodingParseEvent(org.glassfish.grizzly.Connection connection, HttpHeader header, org.glassfish.grizzly.Buffer buffer, TransferEncoding transferEncoding) Method will be called, whenTransferEncodingwill be applied during the parsing/decoding of the certain HTTP message content chunk.voidonTransferEncodingSerializeEvent(org.glassfish.grizzly.Connection connection, HttpHeader header, org.glassfish.grizzly.Buffer buffer, TransferEncoding transferEncoding) Method will be called, whenTransferEncodingwill be applied during the serialization/encoding of the certain HTTP message content chunk.
-
Method Details
-
onDataReceivedEvent
void onDataReceivedEvent(org.glassfish.grizzly.Connection connection, org.glassfish.grizzly.Buffer buffer) Method will be called, whenBufferwill come for processing to theHttpCodecFilter(either request or response).- Parameters:
connection-Connection, the event belongs to.buffer-Bufferto be parsed.
-
onDataSentEvent
void onDataSentEvent(org.glassfish.grizzly.Connection connection, org.glassfish.grizzly.Buffer buffer) Method will be called, whenBuffer, produced by theHttpCodecFilterwill be ready to go to the nextFilterin the chain and finally written on wire.- Parameters:
connection-Connection, the event belongs to.buffer- serializedBuffer.
-
onHeaderParseEvent
Method will be called, when HTTP message header gets parsed (either request or response).- Parameters:
connection-Connection, the event belongs to.header- parsedHttpHeader.size- the size of the parsed header buffer.
-
onHeaderSerializeEvent
void onHeaderSerializeEvent(org.glassfish.grizzly.Connection connection, HttpHeader header, org.glassfish.grizzly.Buffer buffer) Method will be called, when HTTP message header gets serialized (either request or response).- Parameters:
connection-Connection, the event belongs to.header- serializedHttpHeader.buffer- the serialized headerBuffer.
-
onContentChunkParseEvent
Method will be called, when HTTP message content chunk gets parsed (either request or response).- Parameters:
connection-Connection, the event belongs to.content- parsedHttpContent.
-
onContentChunkSerializeEvent
Method will be called, when HTTP message content chunk is prepared to be serialized (either request or response).- Parameters:
connection-Connection, the event belongs to.content-HttpContentto be serialized.
-
onContentEncodingParseEvent
void onContentEncodingParseEvent(org.glassfish.grizzly.Connection connection, HttpHeader header, org.glassfish.grizzly.Buffer buffer, ContentEncoding contentEncoding) Method will be called, whenContentEncodingwill be applied during the parsing/decoding of the certain HTTP message content chunk.- Parameters:
connection-Connection, the event belongs to.header- HTTPHttpHeader, the event belongs to.buffer-Bufferto be parsed/decoded.contentEncoding-ContentEncodingto be applied.
-
onContentEncodingParseResultEvent
void onContentEncodingParseResultEvent(org.glassfish.grizzly.Connection connection, HttpHeader header, org.glassfish.grizzly.Buffer result, ContentEncoding contentEncoding) This method will be called after theContentEncodinghas been applied.- Parameters:
connection-Connection, the event belongs to.header- HTTPHttpHeader, the event belongs to.result- the result of the decode operation.contentEncoding- theContentEncodingthat was applied.- Since:
- 2.3.3
-
onContentEncodingSerializeEvent
void onContentEncodingSerializeEvent(org.glassfish.grizzly.Connection connection, HttpHeader header, org.glassfish.grizzly.Buffer buffer, ContentEncoding contentEncoding) /** Method will be called, whenContentEncodingwill be applied during the serialization/encoding of the certain HTTP message content chunk.- Parameters:
connection-Connection, the event belongs to.header- HTTPHttpHeader, the event belongs to.buffer-Bufferto be serialized/encoded.contentEncoding-ContentEncodingto be applied.
-
onContentEncodingSerializeResultEvent
void onContentEncodingSerializeResultEvent(org.glassfish.grizzly.Connection connection, HttpHeader header, org.glassfish.grizzly.Buffer result, ContentEncoding contentEncoding) Method will be called, whenContentEncodingwill be applied during the serialization/encoding of the certain HTTP message content chunk.- Parameters:
connection-Connection, the event belongs to.header- HTTPHttpHeader, the event belongs to.result- The result of the encoding processes.contentEncoding-ContentEncodingto be applied.- Since:
- 2.3.3
-
onTransferEncodingParseEvent
void onTransferEncodingParseEvent(org.glassfish.grizzly.Connection connection, HttpHeader header, org.glassfish.grizzly.Buffer buffer, TransferEncoding transferEncoding) Method will be called, whenTransferEncodingwill be applied during the parsing/decoding of the certain HTTP message content chunk.- Parameters:
connection-Connection, the event belongs to.header- HTTPHttpHeader, the event belongs to.buffer-Bufferto be parsed/decoded.transferEncoding-TransferEncodingto be applied.
-
onTransferEncodingSerializeEvent
void onTransferEncodingSerializeEvent(org.glassfish.grizzly.Connection connection, HttpHeader header, org.glassfish.grizzly.Buffer buffer, TransferEncoding transferEncoding) Method will be called, whenTransferEncodingwill be applied during the serialization/encoding of the certain HTTP message content chunk.- Parameters:
connection-Connection, the event belongs to.header- HTTPHttpHeader, the event belongs to.buffer-Bufferto be serialized/encoded.transferEncoding-TransferEncodingto be applied.
-
onErrorEvent
void onErrorEvent(org.glassfish.grizzly.Connection connection, HttpPacket httpPacket, Throwable error) Method will be called, when error occurs during theHttpCodecFilterprocessing.- Parameters:
connection-Connection, the event belongs to.connection-HttpPacket, the event belongs to.error- error
-