Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ConsolePump ¶
type ConsolePump struct { ConnsMu sync.RWMutex `json:"-"` Conns map[int64]*websocket.Conn `json:"-"` ConnMuMu sync.RWMutex `json:"-"` ConnMu map[int64]*sync.Mutex `json:"-"` // contains filtered or unexported fields }
ConsolePump handles serving the current logs on the dashboard through Websocket.
func (*ConsolePump) DeregisterConnection ¶
func (cp *ConsolePump) DeregisterConnection(id int64) (ok bool)
DeregisterConnection removes a connection from the pump. Returns boolean if it was removed.
func (*ConsolePump) RegisterConnection ¶
func (cp *ConsolePump) RegisterConnection(conn *websocket.Conn) (id int64)
RegisterConnection will take the already established websocket and add it to the pump.
Click to show internal directories.
Click to hide internal directories.