Interface Http1Upgrader

All Known Implementing Classes:
Http2Upgrader, TyrusUpgrader, WsUpgrader

public interface Http1Upgrader
HTTP/1.1 connection upgrader.
  • Method Details

    • supportedProtocol

      String supportedProtocol()
      Expected value of the protocol upgrade, such as h2c, or websocket. If an implementation supports multiple protocols, please implement this selector for each protocol
      Returns:
      supported protocol
    • upgrade

      ServerConnection upgrade(ConnectionContext ctx, HttpPrologue prologue, WritableHeaders<?> headers)
      Upgrade connection.
      Parameters:
      ctx - connection context
      prologue - http prologue of the upgrade request
      headers - http headers of the upgrade request
      Returns:
      a new connection to use instead of the original Http1Connection, or null if the connection cannot be upgraded