Documentation
¶
Index ¶
- Constants
- type Alert
- type Alerts
- func (a *Alerts) Add(viewName string, alert *Alert, updateExisting bool) (*Alert, error)
- func (a *Alerts) Delete(viewName, alertName string) error
- func (a *Alerts) Get(viewName, alertName string) (*Alert, error)
- func (a *Alerts) List(viewName string) ([]Alert, error)
- func (a *Alerts) Update(viewName string, alert *Alert) (*Alert, error)
- type AppConfigProperties
- type Client
- func (c *Client) Address() string
- func (c *Client) Alerts() *Alerts
- func (c *Client) ClusterNodes() *ClusterNodes
- func (c *Client) Clusters() *Clusters
- func (c *Client) HTTPRequest(httpMethod string, path string, body *bytes.Buffer) (*http.Response, error)
- func (c *Client) HTTPRequestContext(ctx context.Context, httpMethod string, path string, body *bytes.Buffer) (*http.Response, error)
- func (c *Client) Health() (Health, error)
- func (c *Client) HealthString() (string, error)
- func (c *Client) IngestTokens() *IngestTokens
- func (c *Client) Licenses() *Licenses
- func (c *Client) Mutate(mutation interface{}, variables map[string]interface{}) error
- func (c *Client) Notifiers() *Notifiers
- func (c *Client) Parsers() *Parsers
- func (c *Client) Query(query interface{}, variables map[string]interface{}) error
- func (c *Client) QueryJobs() *QueryJobs
- func (c *Client) Repositories() *Repositories
- func (c *Client) Status() (*StatusResponse, error)
- func (c *Client) Token() string
- func (c *Client) Users() *Users
- func (c *Client) Viewer() *Viewer
- func (c *Client) Views() *Views
- type Cluster
- type ClusterNode
- type ClusterNodes
- type Clusters
- func (c *Clusters) ClusterMoveIngestRoutesAwayFromNode(nodeID int) error
- func (c *Clusters) ClusterMoveStorageRouteAwayFromNode(nodeID int) error
- func (c *Clusters) Get() (Cluster, error)
- func (c *Clusters) StartDataRedistribution() error
- func (c *Clusters) UpdateIngestPartitionScheme(desired []IngestPartitionInput) error
- func (c *Clusters) UpdateStoragePartitionScheme(desired []StoragePartitionInput) error
- type Config
- type Health
- type HealthCheck
- type HumioQuery
- type IngestPartition
- type IngestPartitionInput
- type IngestToken
- type IngestTokens
- func (i *IngestTokens) Add(repositoryName string, tokenName string, parserName string) (*IngestToken, error)
- func (i *IngestTokens) Get(repoName, tokenName string) (*IngestToken, error)
- func (i *IngestTokens) List(repo string) ([]IngestToken, error)
- func (i *IngestTokens) Remove(repositoryName string, tokenName string) error
- func (i *IngestTokens) Update(repositoryName string, tokenName string, parserName string) (*IngestToken, error)
- type License
- type Licenses
- type Notifier
- type Notifiers
- func (n *Notifiers) Add(viewName string, notifier *Notifier, force bool) (*Notifier, error)
- func (n *Notifiers) Delete(viewName, notifierName string) error
- func (n *Notifiers) Get(viewName, notifierName string) (*Notifier, error)
- func (n *Notifiers) GetByID(viewName, notifierID string) (*Notifier, error)
- func (n *Notifiers) List(viewName string) ([]Notifier, error)
- func (n *Notifiers) Update(viewName string, notifier *Notifier) (*Notifier, error)
- type OnPremLicense
- type Parser
- type ParserListItem
- type ParserTestCase
- type Parsers
- func (p *Parsers) Add(reposistoryName string, parser *Parser, force bool) error
- func (p *Parsers) Get(reposistoryName string, parserName string) (*Parser, error)
- func (p *Parsers) List(reposistoryName string) ([]ParserListItem, error)
- func (p *Parsers) Remove(reposistoryName string, parserName string) error
- type Query
- type QueryError
- type QueryJobs
- func (q QueryJobs) Create(repository string, query Query) (string, error)
- func (q *QueryJobs) Delete(repository string, id string) error
- func (q *QueryJobs) Poll(repository string, id string) (QueryResult, error)
- func (q *QueryJobs) PollContext(ctx context.Context, repository string, id string) (QueryResult, error)
- type QueryResult
- type QueryResultMetadata
- type RepoListItem
- type Repositories
- type Repository
- type RolePermission
- type StatusResponse
- type StatusValue
- type StoragePartition
- type StoragePartitionInput
- type TrialLicense
- type User
- type UserChangeSet
- type Users
- type View
- type ViewConnection
- type ViewListItem
- type ViewQueryData
- type Viewer
- type Views
Constants ¶
View Source
const NotifierTypeEmail = "EmailNotifier"
View Source
const NotifierTypeOpsGenie = "OpsGenieNotifier"
View Source
const NotifierTypePagerDuty = "PagerDutyNotifier"
View Source
const NotifierTypeSlack = "SlackNotifier"
View Source
const NotifierTypeVictorOps = "VictorOpsNotifier"
View Source
const NotifierTypeWebHook = "WebHookNotifier"
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Alert ¶ added in v0.25.0
type Alert struct {
ID string `yaml:"-" json:"id"`
Name string `yaml:"name" json:"name"`
Query HumioQuery `yaml:"query" json:"query"`
Description string `yaml:"description,omitempty" json:"description"`
ThrottleTimeMillis int `yaml:"throttleTimeMillis" json:"throttleTimeMillis"`
Silenced bool `yaml:"silenced" json:"silenced"`
Notifiers []string `yaml:"notifiers" json:"notifiers"`
LinkURL string `yaml:"linkURL" json:"linkURL"`
Labels []string `yaml:"labels,omitempty" json:"labels,omitempty"`
}
type Alerts ¶ added in v0.25.0
type Alerts struct {
// contains filtered or unexported fields
}
type AppConfigProperties ¶ added in v0.4.0
func ReadPropertiesFile ¶ added in v0.4.0
func ReadPropertiesFile(filename string) (AppConfigProperties, error)
type Client ¶
type Client struct {
// contains filtered or unexported fields
}
func (*Client) ClusterNodes ¶ added in v0.25.0
func (c *Client) ClusterNodes() *ClusterNodes
func (*Client) HTTPRequest ¶ added in v0.25.0
func (*Client) HTTPRequestContext ¶ added in v0.25.0
func (*Client) HealthString ¶ added in v0.25.0
func (*Client) IngestTokens ¶
func (c *Client) IngestTokens() *IngestTokens
func (*Client) Repositories ¶ added in v0.13.0
func (c *Client) Repositories() *Repositories
func (*Client) Status ¶ added in v0.4.0
func (c *Client) Status() (*StatusResponse, error)
type Cluster ¶ added in v0.25.0
type Cluster struct {
Nodes []ClusterNode
ClusterInfoAgeSeconds float64
UnderReplicatedSegmentSize float64
OverReplicatedSegmentSize float64
MissingSegmentSize float64
ProperlyReplicatedSegmentSize float64
TargetUnderReplicatedSegmentSize float64
TargetOverReplicatedSegmentSize float64
TargetMissingSegmentSize float64
TargetProperlyReplicatedSegmentSize float64
IngestPartitions []IngestPartition
StoragePartitions []StoragePartition
}
type ClusterNode ¶ added in v0.25.0
type ClusterNode struct {
Id int
Name string
Uri string
Uuid string
ClusterInfoAgeSeconds float64
InboundSegmentSize float64
OutboundSegmentSize float64
StorageDivergence float64
CanBeSafelyUnregistered bool
CurrentSize float64
PrimarySize float64
SecondarySize float64
TotalSizeOfPrimary float64
TotalSizeOfSecondary float64
FreeOnPrimary float64
FreeOnSecondary float64
WipSize float64
TargetSize float64
Reapply_targetSize float64
SolitarySegmentSize float64
IsAvailable bool
LastHeartbeat string
}
type ClusterNodes ¶ added in v0.25.0
type ClusterNodes struct {
// contains filtered or unexported fields
}
func (*ClusterNodes) Get ¶ added in v0.25.0
func (n *ClusterNodes) Get(nodeID int) (ClusterNode, error)
func (*ClusterNodes) List ¶ added in v0.25.0
func (n *ClusterNodes) List() ([]ClusterNode, error)
func (*ClusterNodes) Unregister ¶ added in v0.25.0
func (n *ClusterNodes) Unregister(nodeID int64, force bool) error
type Clusters ¶ added in v0.25.0
type Clusters struct {
// contains filtered or unexported fields
}
func (*Clusters) ClusterMoveIngestRoutesAwayFromNode ¶ added in v0.25.0
func (*Clusters) ClusterMoveStorageRouteAwayFromNode ¶ added in v0.25.0
func (*Clusters) StartDataRedistribution ¶ added in v0.25.0
func (*Clusters) UpdateIngestPartitionScheme ¶ added in v0.25.0
func (c *Clusters) UpdateIngestPartitionScheme(desired []IngestPartitionInput) error
func (*Clusters) UpdateStoragePartitionScheme ¶ added in v0.25.0
func (c *Clusters) UpdateStoragePartitionScheme(desired []StoragePartitionInput) error
type Config ¶
func DefaultConfig ¶
func DefaultConfig() Config
type Health ¶ added in v0.25.0
type Health struct {
Status StatusValue `json:"status"`
StatusMessage string `json:"statusMessage"`
Uptime string `json:"uptime"`
Version string `json:"version"`
OK []HealthCheck `json:"oks"`
Warn []HealthCheck `json:"warnings"`
Down []HealthCheck `json:"down"`
// contains filtered or unexported fields
}
func (*Health) ChecksMap ¶ added in v0.25.0
func (h *Health) ChecksMap() map[string]HealthCheck
type HealthCheck ¶ added in v0.25.0
type HealthCheck struct {
Name string `json:"name"`
Status StatusValue `json:"status"`
StatusMessage string `json:"statusMessage"`
Fields map[string]interface{} `json:"fields"`
}
type HumioQuery ¶ added in v0.25.0
type IngestPartition ¶ added in v0.25.0
type IngestPartitionInput ¶ added in v0.25.0
type IngestToken ¶
type IngestTokens ¶
type IngestTokens struct {
// contains filtered or unexported fields
}
func (*IngestTokens) Add ¶
func (i *IngestTokens) Add(repositoryName string, tokenName string, parserName string) (*IngestToken, error)
func (*IngestTokens) Get ¶ added in v0.25.0
func (i *IngestTokens) Get(repoName, tokenName string) (*IngestToken, error)
func (*IngestTokens) List ¶
func (i *IngestTokens) List(repo string) ([]IngestToken, error)
func (*IngestTokens) Remove ¶
func (i *IngestTokens) Remove(repositoryName string, tokenName string) error
func (*IngestTokens) Update ¶ added in v0.25.0
func (i *IngestTokens) Update(repositoryName string, tokenName string, parserName string) (*IngestToken, error)
type Notifiers ¶ added in v0.25.0
type Notifiers struct {
// contains filtered or unexported fields
}
type OnPremLicense ¶ added in v0.12.0
type OnPremLicense struct {
ID string
ExpiresAtVal string
IssuedAtVal string
IssuedTo string
NumberOfSeats int
}
func (OnPremLicense) ExpiresAt ¶ added in v0.12.0
func (l OnPremLicense) ExpiresAt() string
func (OnPremLicense) IssuedAt ¶ added in v0.12.0
func (l OnPremLicense) IssuedAt() string
func (OnPremLicense) LicenseType ¶ added in v0.12.0
func (l OnPremLicense) LicenseType() string
type Parser ¶
type Parser struct {
Name string
Tests []ParserTestCase `yaml:",omitempty"`
Example string `yaml:",omitempty"`
Script string `yaml:",flow"`
TagFields []string `yaml:",omitempty"`
}
type ParserListItem ¶
type ParserTestCase ¶
type Parsers ¶
type Parsers struct {
// contains filtered or unexported fields
}
type Query ¶ added in v0.25.0
type Query struct {
QueryString string `json:"queryString"`
Start string `json:"start,omitempty"`
End string `json:"end,omitempty"`
Live bool `json:"isLive,omitempty"`
TimezoneOffset *int `json:"timeZoneOffsetMinutes,omitempty"`
Arguments map[string]string `json:"arguments,omitempty"`
ShowQueryEventDistribution bool `json:"showQueryEventDistribution,omitempty"`
}
type QueryError ¶ added in v0.25.0
type QueryError struct {
// contains filtered or unexported fields
}
func (QueryError) Error ¶ added in v0.25.0
func (e QueryError) Error() string
type QueryJobs ¶ added in v0.25.0
type QueryJobs struct {
// contains filtered or unexported fields
}
func (*QueryJobs) Poll ¶ added in v0.25.0
func (q *QueryJobs) Poll(repository string, id string) (QueryResult, error)
func (*QueryJobs) PollContext ¶ added in v0.25.0
type QueryResult ¶ added in v0.25.0
type QueryResult struct {
Cancelled bool `json:"cancelled"`
Done bool `json:"done"`
Events []map[string]interface{} `json:"events"`
Metadata QueryResultMetadata `json:"metaData"`
}
type QueryResultMetadata ¶ added in v0.25.0
type QueryResultMetadata struct {
EventCount uint64 `json:"eventCount"`
ExtraData map[string]interface{} `json:"extraData"`
FieldOrder []string `json:"fieldOrder"`
IsAggregate bool `json:"isAggregate"`
PollAfter int `json:"pollAfter"`
ProcessedBytes uint64 `json:"processedBytes"`
ProcessedEvents uint64 `json:"processedEvents"`
QueryStart uint64 `json:"queryStart"`
QueryEnd uint64 `json:"queryEnd"`
ResultBufferSize uint64 `json:"resultBufferSize"`
TimeMillis uint64 `json:"timeMillis"`
TotalWork uint64 `json:"totalWork"`
WorkDone uint64 `json:"workDone"`
}
type RepoListItem ¶ added in v0.13.0
type Repositories ¶ added in v0.13.0
type Repositories struct {
// contains filtered or unexported fields
}
func (*Repositories) Create ¶ added in v0.24.0
func (r *Repositories) Create(name string) error
func (*Repositories) Get ¶ added in v0.13.0
func (r *Repositories) Get(name string) (Repository, error)
func (*Repositories) List ¶ added in v0.13.0
func (r *Repositories) List() ([]RepoListItem, error)
type Repository ¶ added in v0.13.0
type RolePermission ¶ added in v0.5.0
type StatusResponse ¶ added in v0.4.0
func (StatusResponse) IsDown ¶ added in v0.25.0
func (s StatusResponse) IsDown() bool
type StatusValue ¶ added in v0.25.0
type StatusValue string
const ( StatusOK StatusValue = "OK" StatusWarn StatusValue = "WARN" StatusDown StatusValue = "DOWN" )
type StoragePartition ¶ added in v0.25.0
type StoragePartitionInput ¶ added in v0.25.0
type TrialLicense ¶ added in v0.12.0
func (TrialLicense) ExpiresAt ¶ added in v0.12.0
func (l TrialLicense) ExpiresAt() string
func (TrialLicense) IssuedAt ¶ added in v0.12.0
func (l TrialLicense) IssuedAt() string
func (TrialLicense) LicenseType ¶ added in v0.12.0
func (l TrialLicense) LicenseType() string
type UserChangeSet ¶
type Users ¶
type Users struct {
// contains filtered or unexported fields
}
type View ¶ added in v0.5.0
type View struct {
Name string
Roles []RolePermission
Connections []ViewConnection
}
type ViewConnection ¶ added in v0.15.0
type ViewListItem ¶ added in v0.11.0
type ViewListItem struct {
Name string
}
type ViewQueryData ¶ added in v0.15.0
type ViewQueryData struct {
Name string
Roles []RolePermission
ViewInfo struct {
Connections []struct {
Repository struct{ Name string }
Filter string
}
} `graphql:"... on View"`
}
Click to show internal directories.
Click to hide internal directories.