Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AlertClient ¶
type AlertClient struct {
// contains filtered or unexported fields
}
AlertClient reads alerts an incident refers to. Read-only: this plugin enriches incidents from alerts and never writes one.
func NewAlertClient ¶
func NewAlertClient(cfg *config.TWConfig) (*AlertClient, error)
func (*AlertClient) Close ¶
func (c *AlertClient) Close() error
func (*AlertClient) GetAlertByID ¶
GetAlertByID looks an alert up across every tenant, which the scope has to name explicitly. An incident carries no tenant of its own, so there is none to scope by; the identifier is a UUID, so the lookup stays unambiguous even though it is unscoped.
type BackendClient ¶
type BackendClient struct {
// contains filtered or unexported fields
}
func NewBackendClient ¶
func NewBackendClient(cfg *config.TWConfig) *BackendClient
func (*BackendClient) GetIncidentAlerts ¶
func (c *BackendClient) GetIncidentAlerts(ctx context.Context, incidentID string) ([]*models.IncidentAlert, error)
func (*BackendClient) GetRecentIncidents ¶
type ClientDependencies ¶
type ClientDependencies struct {
Backend *BackendClient
CM *CustomersManagerClient
ThreadWinds *ThreadWindsClient
Alerts *AlertClient
}
func NewClientDependencies ¶
func NewClientDependencies(cfg *config.TWConfig, ic *CustomersManagerClient) (*ClientDependencies, error)
type CustomersManagerClient ¶
type CustomersManagerClient struct {
Server string `yaml:"server"`
InstanceID string `yaml:"instance_id"`
InstanceKey string `yaml:"instance_key"`
}
func (*CustomersManagerClient) LoadInstanceConfig ¶
func (c *CustomersManagerClient) LoadInstanceConfig() error
type EntityIngestResult ¶
type IngestOutcome ¶
type IngestOutcome struct {
OKCount int
Failures []EntityIngestResult
ProvisioningBlocked bool
}
type ThreadWindsClient ¶
type ThreadWindsClient struct {
// contains filtered or unexported fields
}
func NewThreadWindsClient ¶
func NewThreadWindsClient(ic *CustomersManagerClient) *ThreadWindsClient
func (*ThreadWindsClient) IngestBatch ¶
func (c *ThreadWindsClient) IngestBatch(ctx context.Context, batch []*entities.Entity) IngestOutcome