Versions in this module Expand all Collapse all v0 v0.0.5 Mar 26, 2020 Changes in this version + const ControlMessageAbortEvent + const ControlMessageEndEvent + const ControlMessageStartStreamEvent + const ExeceptedKeepAliveEvent + const ExpectControlType + const ExpectedGeneralMessageType + const ExpectedMetadataType + var Endian = binary.BigEndian + var ErrAPIIssue = errors.New("unable to process request") + var ErrFailedAuth = errors.New("failed auth") + var ErrMissingClient = errors.New("missing required client") + var ErrNoDetectorFound = errors.New("no detector passed") + var ErrNotImplemented = errors.New("currently not implemented") + func IsEndofMessages(msg *ControlMessage) bool + func IsWebsocketError(err error) bool + type ControlMessage struct + Channel string + Event string + Kind string + Progress int + TimestampMS int64 + func ReadControlMessage(data []byte) *ControlMessage + type Data struct + TimeSeriesID string + Value interface{} + Version uint8 + type Detector struct + Created int64 + Creator string + CustomProperties map[string]interface{} + Description string + ID string + LabelResolutions map[string]int64 + LastUpdated int64 + LastUpdatedBy string + Locked bool + MaxDelay int32 + Name string + OverMTSLimit bool + ProgramText string + Rules []Rule + Tags []string + Teams []string + Timezone string + VisualizationOptions Visualization + type Incident struct + type Issue int8 + const Informational + const OK + const System + const User + func (i Issue) String() string + type Message interface + GetType func() string + type MessageGeneral struct + Channel string + Kind string + LogicalTimeStampMs int64 + Message map[string]interface{} + func ReadGeneralMessage(data []byte) *MessageGeneral + func (gen *MessageGeneral) GetType() string + type MessageKeepAlive struct + Event string + TimestampMS int64 + func ReadKeepAliveMessage(data []byte) *MessageKeepAlive + type MessageMetadata struct + Channel string + Kind string + Properties map[string]interface{} + TimeSeriesID string + func ReadMetadataMessage(data []byte) *MessageMetadata + func (meta *MessageMetadata) GetType() string + type MetricDataPoint struct + Channel string + Data []*Data + Flags int8 + Kind string + LogicalTimestampMs int64 + MaxDelayMs int64 + Mtype int8 + Version int8 + func ReadMetricDataPoint(bin []byte) (*MetricDataPoint, error) + type QueryResults struct + Count int32 + Results []json.RawMessage + type Result struct + IssueType Issue + Msg string + Tested string + func CheckInformational(ok bool, tested string) *Result + func CheckSystemIssue(ok bool, tested string) *Result + func CheckUserIssue(ok bool, tested string) *Result + func InformationalIssue(tested string) *Result + func NoIssue(tested string) *Result + func SystemIssue(tested string) *Result + func UserIssue(tested string) *Result + func (r *Result) WithMessage(msg string) *Result + type Rule struct + Description string + DetectLabel string + Disabled bool + Notifications []map[string]string + ParameterizedBody string + ParameterizedSubject string + RunbookURL string + Severity string + Tip string + type Time struct + End int64 + Range int64 + Start int64 + Type string + type Visualization struct + DisableSampling bool + PublishLabelOptions []interface{} + ShowDataMarkers bool + ShowEventLines bool + Time Time + type WebsocketError struct + Channel string + Context map[string]interface{} + ErrorCode int + ErrorType string + Kind string + Message string + func ReadWebsocketError(data []byte) *WebsocketError + func (web *WebsocketError) Error() string