Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func HeadersMiddleware ¶
func HeadersMiddleware() gin.HandlerFunc
Types ¶
type ClientChan ¶
type ClientChan chan string
New event messages are broadcast to all registered client connection channels
type EventStream ¶
type EventStream struct {
// Events are pushed to this channel by the main events-gathering routine
Message chan string
// New client connections
NewClients chan chan string
// Closed client connections
ClosedClients chan chan string
// Total client connections
TotalClients map[chan string]bool
}
It keeps a list of clients those are currently attached and broadcasting events to those clients.
Click to show internal directories.
Click to hide internal directories.