Class JettyWebSocket

  • All Implemented Interfaces:
    io.fabric8.kubernetes.client.http.WebSocket, org.eclipse.jetty.websocket.api.WebSocketConnectionListener, org.eclipse.jetty.websocket.api.WebSocketListener

    public class JettyWebSocket
    extends Object
    implements io.fabric8.kubernetes.client.http.WebSocket, org.eclipse.jetty.websocket.api.WebSocketListener
    • Constructor Detail

      • JettyWebSocket

        public JettyWebSocket​(io.fabric8.kubernetes.client.http.WebSocket.Listener listener)
    • Method Detail

      • send

        public boolean send​(ByteBuffer buffer)
        Specified by:
        send in interface io.fabric8.kubernetes.client.http.WebSocket
      • sendClose

        public boolean sendClose​(int code,
                                 String reason)
        Specified by:
        sendClose in interface io.fabric8.kubernetes.client.http.WebSocket
      • queueSize

        public long queueSize()
        Specified by:
        queueSize in interface io.fabric8.kubernetes.client.http.WebSocket
      • request

        public void request()
        Specified by:
        request in interface io.fabric8.kubernetes.client.http.WebSocket
      • onWebSocketBinary

        public void onWebSocketBinary​(byte[] payload,
                                      int offset,
                                      int len)
        Specified by:
        onWebSocketBinary in interface org.eclipse.jetty.websocket.api.WebSocketListener
      • onWebSocketText

        public void onWebSocketText​(String message)
        Specified by:
        onWebSocketText in interface org.eclipse.jetty.websocket.api.WebSocketListener
      • onWebSocketClose

        public void onWebSocketClose​(int statusCode,
                                     String reason)
        Specified by:
        onWebSocketClose in interface org.eclipse.jetty.websocket.api.WebSocketConnectionListener
      • onWebSocketConnect

        public void onWebSocketConnect​(org.eclipse.jetty.websocket.api.Session session)
        Specified by:
        onWebSocketConnect in interface org.eclipse.jetty.websocket.api.WebSocketConnectionListener
      • onWebSocketError

        public void onWebSocketError​(Throwable cause)
        The semantics here are different than jdk/okhttp - onClose will be invoked after this, if it has not already been called. So we need to skip erroneously notifying
        Specified by:
        onWebSocketError in interface org.eclipse.jetty.websocket.api.WebSocketConnectionListener