Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Agentd ¶
type Agentd struct { // Host is the hostname Agentd is running on. Host string // Port is the port Agentd is running on. Port int // contains filtered or unexported fields }
Agentd is the backend HTTP API.
type Config ¶
type Config struct { Host string Port int Bus messaging.MessageBus Store store.Store TLS *types.TLSOptions RingPool *ringv2.Pool }
Config configures an Agentd.
type Session ¶
type Session struct {
// contains filtered or unexported fields
}
A Session is a server-side connection between a Sensu backend server and the Sensu agent process via the Sensu transport. It is responsible for relaying messages to the message bus on behalf of the agent and from the bus to the agent from other daemons. It handles transport handshaking and transport channel multiplexing/demultiplexing.
func NewSession ¶
func NewSession(cfg SessionConfig, conn transport.Transport, bus messaging.MessageBus, store Store) (*Session, error)
NewSession creates a new Session object given the triple of a transport connection, message bus, and store. The Session is responsible for stopping itself, and does so when it encounters a receive error.
func (*Session) Receiver ¶
func (s *Session) Receiver() chan<- interface{}
Receiver returns the check channel for the session.
type SessionConfig ¶
type SessionConfig struct { Namespace string AgentAddr string AgentName string User string Subscriptions []string RingPool *ringv2.Pool }
A SessionConfig contains all of the ncessary information to initialize an agent session.
type SessionStore ¶
type SessionStore interface { store.EntityStore store.NamespaceStore }
SessionStore specifies the storage requirements of the Session.
type Store ¶
type Store interface { middlewares.AuthStore SessionStore }
Store specifies storage requirements for Agentd.