elastic

package
v1.1.5 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 31, 2025 License: AGPL-3.0 Imports: 12 Imported by: 0 modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ElasticsearchMetric

type ElasticsearchMetric struct {
	Enabled       bool `config:"enabled"`
	IsAgentMode   bool `config:"agent_mode"`
	ClusterHealth bool `config:"cluster_health"`

	ClusterStats bool `config:"cluster_stats"`
	NodeStats    bool `config:"node_stats"`

	IndexStats    bool `config:"index_stats"`
	AllIndexStats bool `config:"all_index_stats"`

	IndexPrimaryStats bool `config:"index_primary_stats"`
	IndexTotalStats   bool `config:"index_total_stats"`

	ClusterState bool   `config:"cluster_state"`
	NodeInfo     bool   `config:"node_info"`
	Interval     string `config:"interval"`
	// contains filtered or unexported fields
}

func New

func New(cfg *config.Config, saveEvent func(item *event.Event) error) (*ElasticsearchMetric, error)

func (*ElasticsearchMetric) Collect

func (m *ElasticsearchMetric) Collect() error

func (*ElasticsearchMetric) CollectClusterHealth

func (m *ElasticsearchMetric) CollectClusterHealth(k string, v *elastic.ElasticsearchMetadata) error

func (*ElasticsearchMetric) CollectClusterState

func (m *ElasticsearchMetric) CollectClusterState(k string, v *elastic.ElasticsearchMetadata) error

func (*ElasticsearchMetric) CollectNodeStats

func (m *ElasticsearchMetric) CollectNodeStats()

func (*ElasticsearchMetric) InitialCollectTask

func (m *ElasticsearchMetric) InitialCollectTask(k string, v *elastic.ElasticsearchMetadata) bool

func (*ElasticsearchMetric) RemoveAllCollectTasks

func (m *ElasticsearchMetric) RemoveAllCollectTasks()

RemoveAllCollectTasks remove all running collect tasks

func (*ElasticsearchMetric) RemoveTask

func (m *ElasticsearchMetric) RemoveTask(taskID string)

RemoveTask remove a running collect task by taskID

func (*ElasticsearchMetric) RemoveTasksByClusterID

func (m *ElasticsearchMetric) RemoveTasksByClusterID(clusterID string)

RemoveTasksByClusterID removes running collect tasks associated with a clusterID

func (*ElasticsearchMetric) SaveIndexStats

func (m *ElasticsearchMetric) SaveIndexStats(v *elastic.ElasticsearchMetadata, indexID, indexName string, primary, total elastic.IndexLevelStats, info *elastic.IndexInfo, shardInfo []elastic.CatShardResponse) error

func (*ElasticsearchMetric) SaveNodeStats

func (m *ElasticsearchMetric) SaveNodeStats(v *elastic.ElasticsearchMetadata, nodeID string, f interface{}, shardInfo interface{}) error

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL