Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Register ¶
func Register(cfg []Config, grpcServer *grpc.Server) ([]*pluginsProto.PluginShort, error)
Types ¶
type Elasticsearch ¶
type Elasticsearch struct { elasticsearchProto.UnimplementedElasticsearchServer // contains filtered or unexported fields }
func (*Elasticsearch) GetLogs ¶
func (e *Elasticsearch) GetLogs(ctx context.Context, getLogsRequest *elasticsearchProto.GetLogsRequest) (*elasticsearchProto.GetLogsResponse, error)
type Response ¶
type Response struct { ScrollID string `json:"_scroll_id"` Took int64 `json:"took"` TimedOut bool `json:"timed_out"` Shards struct { Total int64 `json:"total"` Successful int64 `json:"successful"` Skipped int64 `json:"skipped"` Failed int64 `json:"failed"` } `json:"_shards"` Hits struct { Total struct { Value int64 `json:"value"` Relation string `json:"relation"` } `json:"total"` Hits []map[string]interface{} `json:"hits"` } `json:"hits"` Aggregations struct { LogCount struct { Buckets []struct { KeyAsString string `json:"key_as_string"` Key int64 `json:"key"` DocCount int64 `json:"doc_count"` } `json:"buckets"` } `json:"logcount"` } `json:"aggregations"` }
Response is the structure of successful Elasticsearch API call.
type ResponseError ¶
type ResponseError struct { Error struct { RootCause []struct { Type string `json:"type"` Reason string `json:"reason"` } `json:"root_cause"` Type string `json:"type"` Reason string `json:"reason"` CausedBy struct { Type string `json:"type"` Reason string `json:"reason"` } `json:"caused_by"` } `json:"error"` Status int `json:"status"` }
ResponseError is the structure of failed Elasticsearch API call.
Click to show internal directories.
Click to hide internal directories.