类 StompSubProtocolErrorHandler

    • 方法详细资料

      • handleClientMessageProcessingError

        public Message<byte[]> handleClientMessageProcessingError​(Message<byte[]> clientMessage,
                                                                  Throwable ex)
        从接口复制的说明: SubProtocolErrorHandler
        Handle errors thrown while processing client messages providing an opportunity to prepare the error message or to prevent one from being sent.

        Note that the STOMP protocol requires a server to close the connection after sending an ERROR frame. To prevent an ERROR frame from being sent, a handler could return null and send a notification message through the broker instead, e.g. via a user destination.

        指定者:
        handleClientMessageProcessingError 在接口中 SubProtocolErrorHandler<byte[]>
        参数:
        clientMessage - the client message related to the error, possibly null if error occurred while parsing a WebSocket message
        ex - the cause for the error, never null
        返回:
        the error message to send to the client, or null in which case no message will be sent.