Class UndertowWebSocketSession
java.lang.Object
org.springframework.web.reactive.socket.adapter.AbstractWebSocketSession<T>
org.springframework.web.reactive.socket.adapter.AbstractListenerWebSocketSession<io.undertow.websockets.core.WebSocketChannel>
org.springframework.web.reactive.socket.adapter.UndertowWebSocketSession
- All Implemented Interfaces:
Subscriber<Void>,WebSocketSession
@Deprecated(since="6.2.18",
forRemoval=true)
public class UndertowWebSocketSession
extends AbstractListenerWebSocketSession<io.undertow.websockets.core.WebSocketChannel>
Deprecated, for removal: This API element is subject to removal in a future version.
as of 6.2.18 with no replacement
Spring
WebSocketSession implementation that adapts to an Undertow
WebSocketChannel.- Since:
- 5.0
- Author:
- Violeta Georgieva, Rossen Stoyanchev
-
Nested Class Summary
Nested classes/interfaces inherited from class org.springframework.web.reactive.socket.adapter.AbstractListenerWebSocketSession
AbstractListenerWebSocketSession.WebSocketSendProcessor -
Field Summary
Fields inherited from class org.springframework.web.reactive.socket.adapter.AbstractWebSocketSession
logger -
Constructor Summary
ConstructorsConstructorDescriptionUndertowWebSocketSession(io.undertow.websockets.core.WebSocketChannel channel, HandshakeInfo info, DataBufferFactory factory) Deprecated, for removal: This API element is subject to removal in a future version.UndertowWebSocketSession(io.undertow.websockets.core.WebSocketChannel channel, HandshakeInfo info, DataBufferFactory factory, reactor.core.publisher.Sinks.Empty<Void> completionSink) Deprecated, for removal: This API element is subject to removal in a future version. -
Method Summary
Modifier and TypeMethodDescriptionprotected booleanDeprecated, for removal: This API element is subject to removal in a future version.Whether the underlying WebSocket API has flow control and can suspend and resume the receiving of messages.reactor.core.publisher.Mono<Void>close(CloseStatus status) Deprecated, for removal: This API element is subject to removal in a future version.Close the WebSocket session with the given status.booleanisOpen()Deprecated, for removal: This API element is subject to removal in a future version.Whether the underlying connection is open.protected voidDeprecated, for removal: This API element is subject to removal in a future version.Resume receiving new message(s) after demand is generated by the downstream Subscriber.protected booleansendMessage(WebSocketMessage message) Deprecated, for removal: This API element is subject to removal in a future version.Send the given WebSocket message.protected voidDeprecated, for removal: This API element is subject to removal in a future version.Suspend receiving until received message(s) are processed and more demand is generated by the downstream Subscriber.Methods inherited from class org.springframework.web.reactive.socket.adapter.AbstractListenerWebSocketSession
closeStatus, getSendProcessor, onComplete, onError, onNext, onSubscribe, receive, sendMethods inherited from class org.springframework.web.reactive.socket.adapter.AbstractWebSocketSession
binaryMessage, bufferFactory, getAttributes, getDelegate, getHandshakeInfo, getId, getLogPrefix, pingMessage, pongMessage, textMessage, toStringMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface org.springframework.web.reactive.socket.WebSocketSession
close
-
Constructor Details
-
UndertowWebSocketSession
public UndertowWebSocketSession(io.undertow.websockets.core.WebSocketChannel channel, HandshakeInfo info, DataBufferFactory factory) Deprecated, for removal: This API element is subject to removal in a future version. -
UndertowWebSocketSession
public UndertowWebSocketSession(io.undertow.websockets.core.WebSocketChannel channel, HandshakeInfo info, DataBufferFactory factory, @Nullable reactor.core.publisher.Sinks.Empty<Void> completionSink) Deprecated, for removal: This API element is subject to removal in a future version.
-
-
Method Details
-
canSuspendReceiving
protected boolean canSuspendReceiving()Deprecated, for removal: This API element is subject to removal in a future version.Description copied from class:AbstractListenerWebSocketSessionWhether the underlying WebSocket API has flow control and can suspend and resume the receiving of messages.Note: Sub-classes are encouraged to start out in suspended mode, if possible, and wait until demand is received.
- Specified by:
canSuspendReceivingin classAbstractListenerWebSocketSession<io.undertow.websockets.core.WebSocketChannel>
-
suspendReceiving
protected void suspendReceiving()Deprecated, for removal: This API element is subject to removal in a future version.Description copied from class:AbstractListenerWebSocketSessionSuspend receiving until received message(s) are processed and more demand is generated by the downstream Subscriber.Note: if the underlying WebSocket API does not provide flow control for receiving messages, this method should be a no-op and
AbstractListenerWebSocketSession.canSuspendReceiving()should returnfalse.- Specified by:
suspendReceivingin classAbstractListenerWebSocketSession<io.undertow.websockets.core.WebSocketChannel>
-
resumeReceiving
protected void resumeReceiving()Deprecated, for removal: This API element is subject to removal in a future version.Description copied from class:AbstractListenerWebSocketSessionResume receiving new message(s) after demand is generated by the downstream Subscriber.Note: if the underlying WebSocket API does not provide flow control for receiving messages, this method should be a no-op and
AbstractListenerWebSocketSession.canSuspendReceiving()should returnfalse.- Specified by:
resumeReceivingin classAbstractListenerWebSocketSession<io.undertow.websockets.core.WebSocketChannel>
-
sendMessage
Deprecated, for removal: This API element is subject to removal in a future version.Description copied from class:AbstractListenerWebSocketSessionSend the given WebSocket message.Note: Sub-classes are responsible for releasing the payload data buffer, once fully written, if pooled buffers apply to the underlying container.
- Specified by:
sendMessagein classAbstractListenerWebSocketSession<io.undertow.websockets.core.WebSocketChannel>- Throws:
IOException
-
isOpen
public boolean isOpen()Deprecated, for removal: This API element is subject to removal in a future version.Description copied from interface:WebSocketSessionWhether the underlying connection is open. -
close
Deprecated, for removal: This API element is subject to removal in a future version.Description copied from interface:WebSocketSessionClose the WebSocket session with the given status.- Parameters:
status- the close status
-