public interface StompSessionHandler extends StompFrameHandler
This contract also extends StompFrameHandler in order to handle
STOMP ERROR frames received from the broker.
Implementations of this interface should consider extending
StompSessionHandlerAdapter.
StompSessionHandlerAdapter| Modifier and Type | Method and Description |
|---|---|
void |
afterConnected(StompSession session,
StompHeaders connectedHeaders)
Invoked when the session is ready to use, i.e.
|
void |
handleException(StompSession session,
StompCommand command,
StompHeaders headers,
byte[] payload,
java.lang.Throwable exception)
Handle any exception arising while processing a STOMP frame such as a
failure to convert the payload or an unhandled exception in the
application
StompFrameHandler. |
void |
handleTransportError(StompSession session,
java.lang.Throwable exception)
Handle a low level transport error which could be an I/O error or a
failure to encode or decode a STOMP message.
|
getPayloadType, handleFramevoid afterConnected(StompSession session, StompHeaders connectedHeaders)
session - the client STOMP sessionconnectedHeaders - the STOMP CONNECTED frame headersvoid handleException(StompSession session, @Nullable StompCommand command, StompHeaders headers, byte[] payload, java.lang.Throwable exception)
StompFrameHandler.session - the client STOMP sessioncommand - the STOMP command of the frameheaders - the headerspayload - the raw payloadexception - the exceptionvoid handleTransportError(StompSession session, java.lang.Throwable exception)
Note that
ConnectionLostException will be passed into this method when the
connection is lost rather than closed normally via
StompSession.disconnect().
session - the client STOMP sessionexception - the exception that occurred