elasticsearch

package
v0.5.3 Latest Latest
Warning

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

Go to latest
Published: Apr 14, 2025 License: GPL-3.0 Imports: 0 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ClusterStats

type ClusterStats struct {
	Nodes       map[string]NodeInfo `json:"nodes"`
	ClusterName string              `json:"cluster_name"`
}

type HealthResponse

type HealthResponse struct {
	ClusterName                 string  `json:"cluster_name"`
	Status                      string  `json:"status"`
	TimedOut                    bool    `json:"timed_out"`
	NumberOfNodes               int     `json:"number_of_nodes"`
	NumberOfDataNodes           int     `json:"number_of_data_nodes"`
	ActivePrimaryShards         int     `json:"active_primary_shards"`
	ActiveShards                int     `json:"active_shards"`
	RelocatingShards            int     `json:"relocating_shards"`
	InitializingShards          int     `json:"initializing_shards"`
	UnassignedShards            int     `json:"unassigned_shards"`
	DelayedUnassignedShards     int     `json:"delayed_unassigned_shards"`
	NumberOfPendingTasks        int     `json:"number_of_pending_tasks"`
	NumberOfInFlightFetch       int     `json:"number_of_in_flight_fetch"`
	TaskMaxWaitingInQueueMillis int     `json:"task_max_waiting_in_queue_millis"`
	ActiveShardsPercentAsNumber float64 `json:"active_shards_percent_as_number"`
}

type IngestInfo

type IngestInfo struct {
	Total     IngestStats             `json:"total"`
	Pipelines map[string]PipelineInfo `json:"pipelines"`
}

type IngestStats

type IngestStats struct {
	Count   float64 `json:"count"`
	Current float64 `json:"current"`
	Failed  float64 `json:"failed"`
}

type NodeInfo

type NodeInfo struct {
	IP     string     `json:"ip"`
	Ingest IngestInfo `json:"ingest"`
}

type PipelineInfo

type PipelineInfo struct {
	Count   float64 `json:"count"`
	Current float64 `json:"current"`
	Failed  float64 `json:"failed"`
}

type Query

type Query struct {
	QueryString *QueryString `json:"query_string,omitempty"`
}

https://www.elastic.co/guide/en/elasticsearch/reference/current/query-dsl-query-string-query.html

type SearchHit

type SearchHit struct {
	Index  string                 `json:"_index"`
	Type   string                 `json:"_type"`
	Source map[string]interface{} `json:"_source"`
	ID     string                 `json:"_id"`
}

type SearchHits

type SearchHits struct {
	Total SearchTotal `json:"total"`
	Hits  []SearchHit `json:"hits"`
}

type SearchRequest

type SearchRequest struct {
	Query Query `json:"query"`
}

type SearchTotal

type SearchTotal struct {
	Value uint `json:"value"`
}

type Snapshot added in v0.5.0

type Snapshot struct {
	Snapshot           string   `json:"snapshot"`
	UUID               string   `json:"uuid"`
	Repository         string   `json:"repository"`
	Indices            []string `json:"indices"`
	DataStreams        []string `json:"data_streams"`
	IncludeGlobalState bool     `json:"include_global_state"`
	State              string   `json:"state"`
	StartTimeInMillis  int      `json:"start_time_in_millis"`
	EndTimeInMillis    int      `json:"end_time_in_millis"`
	DurationInMillis   int      `json:"duration_in_millis"`
	Shards             struct {
		Total      int `json:"total"`
		Failed     int `json:"failed"`
		Successful int `json:"successful"`
	} `json:"shards"`
}

type SnapshotResponse added in v0.5.0

type SnapshotResponse struct {
	Snapshots []Snapshot `json:"snapshots"`
	Total     int        `json:"total"`
	Remaining int        `json:"remaining"`
}

Jump to

Keyboard shortcuts

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