Interface MqttWebSocketConfig


@DoNotImplement public interface MqttWebSocketConfig
Configuration for a WebSocket transport to use by MQTT clients.
Since:
1.0
  • Field Details

    • DEFAULT_SERVER_PATH

      @NotNull static final @NotNull String DEFAULT_SERVER_PATH
      The default WebSocket server path.
      See Also:
    • DEFAULT_QUERY_STRING

      @NotNull static final @NotNull String DEFAULT_QUERY_STRING
      The default WebSocket query string.
      See Also:
    • DEFAULT_MQTT_SUBPROTOCOL

      @NotNull static final @NotNull String DEFAULT_MQTT_SUBPROTOCOL
      The default WebSocket subprotocol.

      See the WebSocket Subprotocol Name Registry

      See Also:
    • DEFAULT_HANDSHAKE_TIMEOUT_MS

      static final int DEFAULT_HANDSHAKE_TIMEOUT_MS
      The default websocket handshake timeout in milliseconds.
      Since:
      1.2
      See Also:
    • DEFAULT_HTTP_HEADERS

      @NotNull static final @NotNull Map<String,String> DEFAULT_HTTP_HEADERS
      The default map of headers.
      Since:
      1.2.3
  • Method Details

    • builder

      @NotNull static @NotNull MqttWebSocketConfigBuilder builder()
      Creates a builder for a WebSocket configuration.
      Returns:
      the created builder for a WebSocket configuration.
    • getServerPath

      @NotNull @NotNull String getServerPath()
      Returns:
      the WebSocket server path.
    • getQueryString

      @NotNull @NotNull String getQueryString()
      Returns:
      the WebSocket query string.
    • getSubprotocol

      @NotNull @NotNull String getSubprotocol()
      Returns:
      the WebSocket subprotocol.
    • getHandshakeTimeoutMs

      int getHandshakeTimeoutMs()
      Returns:
      the websocket handshake timeout in milliseconds.
      Since:
      1.2
    • getHttpHeaders

      @NotNull @NotNull Map<String,String> getHttpHeaders()
      Returns:
      map of already set headers.
      Since:
      1.2.3
    • extend

      @NotNull @NotNull MqttWebSocketConfigBuilder extend()
      Creates a builder for extending this WebSocket configuration.
      Returns:
      the created builder.
      Since:
      1.1