Absinthe.GraphqlWS.Transport.handle_info

You're seeing just the function handle_info, go back to Absinthe.GraphqlWS.Transport module for more information.
Link to this function

handle_info(message, socket)

View Source

Specs

handle_info(term(), socket()) :: reply_message()

Receive messages from inside the house.

  • :keepalive - Regularly send messages with opcode of 0x09, ie :ping. The graphql-ws library has a strong opinion that it does not want to implement client-side keepalive, so in order to keep the websocket from closing we need to send it messages.

  • subscription:data - After we subscribe to an Absinthe subscription, we may receive messages for the relevant subscription. The graphql-ws will have sent us an id along with the subscription query, so we need to map our internal topic back to that id in order for the client to figure out what to do with our message.

  • :complete - If we get a query or a mutation on the websocket, we're supposed to reply with a Next message followed by a Complete message. We follow through on the latter by putting a message on our process queue.

  • fallthrough - If c:Absinthe.GraphqlWs.Socket.handle_message/2 is defined on the socket, then uncaught messages will be sent there.