Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Bot ¶
type Bot struct { SlackWebhookURL string LogEntrySource IncidentLogEntrySource Log *logrus.Logger }
type BotService ¶
type BotService struct {
// contains filtered or unexported fields
}
func NewBotService ¶
func (*BotService) JSONEndpoints ¶
func (s *BotService) JSONEndpoints() map[string]map[string]server.JSONEndpoint
func (*BotService) JSONMiddleware ¶
func (s *BotService) JSONMiddleware(j server.JSONEndpoint) server.JSONEndpoint
func (*BotService) Middleware ¶
func (s *BotService) Middleware(h http.Handler) http.Handler
func (*BotService) Prefix ¶
func (s *BotService) Prefix() string
type GCPLogAdmin ¶
func (*GCPLogAdmin) GetLogAdminFilter ¶
func (g *GCPLogAdmin) GetLogAdminFilter(payload IncidentPayload) string
func (*GCPLogAdmin) GetLogEntries ¶
func (g *GCPLogAdmin) GetLogEntries(payload IncidentPayload) ([]IncidentLogEntry, error)
type Incident ¶
type Incident struct { IncidentID string `json:"incident_id"` ResourceID string `json:"resource_id"` ResourceName string `json:"resource_name"` State string `json:"state"` StartedAt int64 `json:"started_at"` EndedAt *int64 `json:"ended_at"` PolicyName string `json:"policy_name"` ConditionName string `json:"condition_name"` URL string `json:"url"` Summary string `json:"summary"` }
func (*Incident) EndedAtTime ¶
func (*Incident) StartedAtTime ¶
type IncidentLogEntry ¶
type IncidentLogEntrySource ¶
type IncidentLogEntrySource interface { GetLogAdminFilter(payload IncidentPayload) string GetLogEntries(payload IncidentPayload) ([]IncidentLogEntry, error) }
type IncidentPayload ¶
func (*IncidentPayload) Populate ¶
func (i *IncidentPayload) Populate(input string) error
Click to show internal directories.
Click to hide internal directories.