Class PerConnectionApolloHandler

java.lang.Object
io.leangen.graphql.spqr.spring.web.apollo.PerConnectionApolloHandler
All Implemented Interfaces:
org.springframework.web.socket.SubProtocolCapable, org.springframework.web.socket.WebSocketHandler

public class PerConnectionApolloHandler extends Object implements org.springframework.web.socket.WebSocketHandler, org.springframework.web.socket.SubProtocolCapable
  • Constructor Details

    • PerConnectionApolloHandler

      public PerConnectionApolloHandler(graphql.GraphQL graphQL, GraphQLWebSocketExecutor executor, org.springframework.scheduling.TaskScheduler taskScheduler, int keepAliveInterval, int sendTimeLimit, int sendBufferSizeLimit)
  • Method Details

    • afterConnectionEstablished

      public void afterConnectionEstablished(org.springframework.web.socket.WebSocketSession session) throws Exception
      Specified by:
      afterConnectionEstablished in interface org.springframework.web.socket.WebSocketHandler
      Throws:
      Exception
    • handleMessage

      public void handleMessage(org.springframework.web.socket.WebSocketSession session, org.springframework.web.socket.WebSocketMessage<?> message) throws Exception
      Specified by:
      handleMessage in interface org.springframework.web.socket.WebSocketHandler
      Throws:
      Exception
    • handleTransportError

      public void handleTransportError(org.springframework.web.socket.WebSocketSession session, Throwable exception)
      Specified by:
      handleTransportError in interface org.springframework.web.socket.WebSocketHandler
    • afterConnectionClosed

      public void afterConnectionClosed(org.springframework.web.socket.WebSocketSession session, org.springframework.web.socket.CloseStatus closeStatus)
      Specified by:
      afterConnectionClosed in interface org.springframework.web.socket.WebSocketHandler
    • supportsPartialMessages

      public boolean supportsPartialMessages()
      Specified by:
      supportsPartialMessages in interface org.springframework.web.socket.WebSocketHandler
    • getSubProtocols

      public List<String> getSubProtocols()
      Specified by:
      getSubProtocols in interface org.springframework.web.socket.SubProtocolCapable
    • cancelAll

      @PreDestroy public void cancelAll()
    • decorateSession

      protected org.springframework.web.socket.WebSocketSession decorateSession(org.springframework.web.socket.WebSocketSession session)