Documentation
¶
Index ¶
- Variables
- func EmitCheckEvent(probeId int64, checkId int64, eventName string, event interface{}) error
- func GetOrgQuotas(c *middleware.Context) *rbody.ApiResponse
- func GetQuotas(c *middleware.Context) *rbody.ApiResponse
- func GetUsage(c *middleware.Context) *rbody.ApiResponse
- func HandleEndpointCreated(event *events.EndpointCreated) error
- func HandleEndpointDeleted(event *events.EndpointDeleted) error
- func HandleEndpointUpdated(event *events.EndpointUpdated) error
- func HandleProbeSessionCreated(event *events.ProbeSessionCreated) error
- func HandleProbeSessionDeleted(event *events.ProbeSessionDeleted) error
- func HandleProbeUpdated(event *events.ProbeUpdated) error
- func Heartbeat(c *middleware.Context)
- func InitCollectorController(metrics met.Backend)
- func NotFoundHandler(c *middleware.Context)
- func Register(r *macaron.Macaron)
- func ShutdownController()
- func SocketIO(c *middleware.Context)
- func UpdateOrgQuota(c *middleware.Context) *rbody.ApiResponse
- func V1AddCollector(c *middleware.Context, probe m.ProbeDTO)
- func V1AddEndpoint(c *middleware.Context, cmd m.AddEndpointCommand)
- func V1AddMonitor(c *middleware.Context, cmd m.AddMonitorCommand)
- func V1DeleteCollector(c *middleware.Context)
- func V1DeleteEndpoint(c *middleware.Context)
- func V1DeleteMonitor(c *middleware.Context)
- func V1DiscoverEndpoint(c *middleware.Context, cmd m.DiscoverEndpointCmd)
- func V1ElasticsearchProxy(c *middleware.Context)
- func V1GetCollectorById(c *middleware.Context)
- func V1GetCollectorLocations(c *middleware.Context)
- func V1GetCollectors(c *middleware.Context, query m.GetProbesQuery)
- func V1GetEndpointById(c *middleware.Context)
- func V1GetEndpoints(c *middleware.Context, query m.GetEndpointsQuery)
- func V1GetMonitorTypes(c *middleware.Context)
- func V1GetMonitors(c *middleware.Context, query m.GetMonitorsQuery)
- func V1GetOrgQuotas(c *middleware.Context)
- func V1GraphiteProxy(c *middleware.Context)
- func V1UpdateCollector(c *middleware.Context, probe m.ProbeDTO)
- func V1UpdateEndpoint(c *middleware.Context, cmd m.UpdateEndpointCommand)
- func V1UpdateMonitor(c *middleware.Context, cmd m.UpdateMonitorCommand)
- type CollectorContext
- func (c *CollectorContext) EmitReady() error
- func (c *CollectorContext) OnDisconnection()
- func (c *CollectorContext) OnEvent(msg *schema.ProbeEvent)
- func (c *CollectorContext) OnEventOld(msg *probeEventOld)
- func (c *CollectorContext) OnResults(results []*schema.MetricData)
- func (c *CollectorContext) Refresh()
- func (c *CollectorContext) Remove() error
- type ContextCache
- func (s *ContextCache) Emit(id string, event string, payload interface{})
- func (c *ContextCache) Refresh(collectorId int64)
- func (c *ContextCache) RefreshLoop()
- func (c *ContextCache) RefreshQueue()
- func (s *ContextCache) Remove(id string)
- func (s *ContextCache) Set(id string, context *CollectorContext)
- func (c *ContextCache) Shutdown()
- type ReadyPayload
Constants ¶
This section is empty.
Variables ¶
Functions ¶
func EmitCheckEvent ¶
func GetOrgQuotas ¶
func GetOrgQuotas(c *middleware.Context) *rbody.ApiResponse
func GetQuotas ¶
func GetQuotas(c *middleware.Context) *rbody.ApiResponse
func GetUsage ¶
func GetUsage(c *middleware.Context) *rbody.ApiResponse
func HandleEndpointCreated ¶
func HandleEndpointCreated(event *events.EndpointCreated) error
func HandleEndpointDeleted ¶
func HandleEndpointDeleted(event *events.EndpointDeleted) error
func HandleEndpointUpdated ¶
func HandleEndpointUpdated(event *events.EndpointUpdated) error
func HandleProbeSessionCreated ¶
func HandleProbeSessionCreated(event *events.ProbeSessionCreated) error
func HandleProbeSessionDeleted ¶
func HandleProbeSessionDeleted(event *events.ProbeSessionDeleted) error
func HandleProbeUpdated ¶
func HandleProbeUpdated(event *events.ProbeUpdated) error
func Heartbeat ¶
func Heartbeat(c *middleware.Context)
func InitCollectorController ¶
func NotFoundHandler ¶
func NotFoundHandler(c *middleware.Context)
func ShutdownController ¶
func ShutdownController()
func SocketIO ¶
func SocketIO(c *middleware.Context)
func UpdateOrgQuota ¶
func UpdateOrgQuota(c *middleware.Context) *rbody.ApiResponse
func V1AddCollector ¶
func V1AddCollector(c *middleware.Context, probe m.ProbeDTO)
func V1AddEndpoint ¶
func V1AddEndpoint(c *middleware.Context, cmd m.AddEndpointCommand)
func V1AddMonitor ¶
func V1AddMonitor(c *middleware.Context, cmd m.AddMonitorCommand)
func V1DeleteCollector ¶
func V1DeleteCollector(c *middleware.Context)
func V1DeleteEndpoint ¶
func V1DeleteEndpoint(c *middleware.Context)
func V1DeleteMonitor ¶
func V1DeleteMonitor(c *middleware.Context)
func V1DiscoverEndpoint ¶
func V1DiscoverEndpoint(c *middleware.Context, cmd m.DiscoverEndpointCmd)
func V1ElasticsearchProxy ¶
func V1ElasticsearchProxy(c *middleware.Context)
func V1GetCollectorById ¶
func V1GetCollectorById(c *middleware.Context)
func V1GetCollectorLocations ¶
func V1GetCollectorLocations(c *middleware.Context)
func V1GetCollectors ¶
func V1GetCollectors(c *middleware.Context, query m.GetProbesQuery)
func V1GetEndpointById ¶
func V1GetEndpointById(c *middleware.Context)
func V1GetEndpoints ¶
func V1GetEndpoints(c *middleware.Context, query m.GetEndpointsQuery)
func V1GetMonitorTypes ¶
func V1GetMonitorTypes(c *middleware.Context)
func V1GetMonitors ¶
func V1GetMonitors(c *middleware.Context, query m.GetMonitorsQuery)
func V1GetOrgQuotas ¶
func V1GetOrgQuotas(c *middleware.Context)
func V1GraphiteProxy ¶
func V1GraphiteProxy(c *middleware.Context)
func V1UpdateCollector ¶
func V1UpdateCollector(c *middleware.Context, probe m.ProbeDTO)
func V1UpdateEndpoint ¶
func V1UpdateEndpoint(c *middleware.Context, cmd m.UpdateEndpointCommand)
func V1UpdateMonitor ¶
func V1UpdateMonitor(c *middleware.Context, cmd m.UpdateMonitorCommand)
Types ¶
type CollectorContext ¶
type CollectorContext struct {
*auth.SignedInUser
Probe *m.ProbeDTO
Socket socketio.Socket
Session *m.ProbeSession
LastRefresh time.Time
// contains filtered or unexported fields
}
func (*CollectorContext) EmitReady ¶
func (c *CollectorContext) EmitReady() error
func (*CollectorContext) OnDisconnection ¶
func (c *CollectorContext) OnDisconnection()
func (*CollectorContext) OnEvent ¶
func (c *CollectorContext) OnEvent(msg *schema.ProbeEvent)
func (*CollectorContext) OnEventOld ¶
func (c *CollectorContext) OnEventOld(msg *probeEventOld)
func (*CollectorContext) OnResults ¶
func (c *CollectorContext) OnResults(results []*schema.MetricData)
func (*CollectorContext) Refresh ¶
func (c *CollectorContext) Refresh()
func (*CollectorContext) Remove ¶
func (c *CollectorContext) Remove() error
type ContextCache ¶
type ContextCache struct {
sync.RWMutex
Contexts map[string]*CollectorContext
// contains filtered or unexported fields
}
func NewContextCache ¶
func NewContextCache() *ContextCache
func (*ContextCache) Emit ¶
func (s *ContextCache) Emit(id string, event string, payload interface{})
func (*ContextCache) Refresh ¶
func (c *ContextCache) Refresh(collectorId int64)
func (*ContextCache) RefreshLoop ¶
func (c *ContextCache) RefreshLoop()
func (*ContextCache) RefreshQueue ¶
func (c *ContextCache) RefreshQueue()
func (*ContextCache) Remove ¶
func (s *ContextCache) Remove(id string)
func (*ContextCache) Set ¶
func (s *ContextCache) Set(id string, context *CollectorContext)
func (*ContextCache) Shutdown ¶
func (c *ContextCache) Shutdown()
type ReadyPayload ¶
type ReadyPayload struct {
Collector *m.ProbeDTO `json:"collector"`
MonitorTypes []m.MonitorTypeDTO `json:"monitor_types"`
SocketId string `json:"socket_id"`
}
Source Files
¶
Click to show internal directories.
Click to hide internal directories.