Class WebsocketHttpSessionAttachRecorder

java.lang.Object
com.vaadin.quarkus.WebsocketHttpSessionAttachRecorder

public class WebsocketHttpSessionAttachRecorder extends Object
Attaches the HTTP session of the upgrade request to WebSocket connections, so that Vaadin Push over WebSocket finds the Vaadin session.
Since:
1.1
  • Constructor Details

    • WebsocketHttpSessionAttachRecorder

      public WebsocketHttpSessionAttachRecorder()
  • Method Details

    • createWebSocketHandler

      public io.vertx.core.Handler<io.vertx.ext.web.RoutingContext> createWebSocketHandler(io.undertow.servlet.api.DeploymentManager deploymentManager)
      Gets an adapted version of VertxWebSocketHandler that attaches upgrade request HTTP session to the Undertow WebSocket HttpExchange.

      The WebSocket container is the one Quarkus registers as the ServerContainer servlet context attribute. The handler reads only the executor and the server extensions from the deployment info, so a new info with the same executor Quarkus uses is enough: Quarkus adds no server extensions.

      Parameters:
      deploymentManager - deployment manager
      Returns:
      an adapted version of VertxWebSocketHandler
      Since:
      25.4