RequestUpgradeStrategy for the Jakarta WebSocket API 2.1+.
This strategy serves as a fallback if no specific server has been detected. It can also be used with Jakarta EE 10 level servers such as Tomcat 10.1 and Undertow 2.3 directly, relying on their built-in Jakarta WebSocket 2.1 support.
jakarta.websocket.server.ServerContainer#upgradeHttpToWebSocket
| Modifier and Type | Field and Description |
|---|---|
| private Long | |
| private Integer | |
| private Long | |
| private Integer | |
| private static final String | |
| private ServerContainer |
| Access | Constructor and Description |
|---|---|
| public |
| Modifier and Type | Method and Description |
|---|---|
| public Long | |
| protected ServerContainer | |
| public Integer | |
| public Long | |
| public Integer | |
| private void | |
| public void | setAsyncSendTimeout(Long timeoutInMillis)
Exposes the underlying config option on
|
| public void | setMaxBinaryMessageBufferSize(Integer bufferSize)
Exposes the underlying config option on
|
| public void | setMaxSessionIdleTimeout(Long timeoutInMillis)
Exposes the underlying config option on
|
| public void | setMaxTextMessageBufferSize(Integer bufferSize)
Exposes the underlying config option on
|
| public Mono | upgrade(ServerWebExchange
the current exchange exchange, WebSocketHandler handler for the WebSocket session handler, String the selected sub-protocol got the handler subProtocol, Supplier<HandshakeInfo> factory to create HandshakeInfo for the WebSocket session handshakeInfoFactory)Implements org. Upgrade to a WebSocket session and handle it with the given handler. |
| protected void | upgradeHttpToWebSocket(HttpServletRequest request, HttpServletResponse response, ServerEndpointConfig endpointConfig, Map<String, String> pathParams)
|
| asyncSendTimeout | back to summary |
|---|---|
| private Long asyncSendTimeout
| |
| maxBinaryMessageBufferSize | back to summary |
|---|---|
| private Integer maxBinaryMessageBufferSize
| |
| maxSessionIdleTimeout | back to summary |
|---|---|
| private Long maxSessionIdleTimeout
| |
| maxTextMessageBufferSize | back to summary |
|---|---|
| private Integer maxTextMessageBufferSize
| |
| SERVER_CONTAINER_ATTR | back to summary |
|---|---|
| private static final String SERVER_CONTAINER_ATTR | |
| serverContainer | back to summary |
|---|---|
| private ServerContainer serverContainer
| |
| StandardWebSocketUpgradeStrategy | back to summary |
|---|---|
| public StandardWebSocketUpgradeStrategy() | |
| getAsyncSendTimeout | back to summary |
|---|---|
public Long getAsyncSendTimeout()
| |
| getContainer | back to summary |
|---|---|
| protected ServerContainer getContainer(HttpServletRequest request) | |
| getMaxBinaryMessageBufferSize | back to summary |
|---|---|
public Integer getMaxBinaryMessageBufferSize()
| |
| getMaxSessionIdleTimeout | back to summary |
|---|---|
public Long getMaxSessionIdleTimeout()
| |
| getMaxTextMessageBufferSize | back to summary |
|---|---|
public Integer getMaxTextMessageBufferSize()
| |
| initServerContainer | back to summary |
|---|---|
| private void initServerContainer(ServerContainer serverContainer) | |
| setAsyncSendTimeout | back to summary |
|---|---|
| public void setAsyncSendTimeout(Long timeoutInMillis) Exposes the underlying config option on
| |
| setMaxBinaryMessageBufferSize | back to summary |
|---|---|
| public void setMaxBinaryMessageBufferSize(Integer bufferSize) Exposes the underlying config option on
| |
| setMaxSessionIdleTimeout | back to summary |
|---|---|
| public void setMaxSessionIdleTimeout(Long timeoutInMillis) Exposes the underlying config option on
| |
| setMaxTextMessageBufferSize | back to summary |
|---|---|
| public void setMaxTextMessageBufferSize(Integer bufferSize) Exposes the underlying config option on
| |
| upgrade | back to summary |
|---|---|
| public Mono Implements org. Doc from org. Upgrade to a WebSocket session and handle it with the given handler.
| |
| upgradeHttpToWebSocket | back to summary |
|---|---|
| protected void upgradeHttpToWebSocket(HttpServletRequest request, HttpServletResponse response, ServerEndpointConfig endpointConfig, Map<String, String> pathParams) throws Exception | |