es

package
v0.0.23 Latest Latest
Warning

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

Go to latest
Published: Apr 19, 2023 License: MIT Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AllIndex

func AllIndex() interface{}

func DeleteIndex

func DeleteIndex(indexName string) interface{}

func GetIndexPre added in v0.0.23

func GetIndexPre() string

func GroupField

func GroupField(indexName, field string, size, minCount int, excludeValues []string) []byte

func Init

func Init()

func InsertEsLog

func InsertEsLog(logInfo interface{})

func TestLog

func TestLog()

Types

type IndexInfo

type IndexInfo struct {
	Name  string `json:"name"`
	Count int    `json:"count"`
	Size  string `json:"size"`
}

type QueryParams added in v0.0.22

type QueryParams struct {
	Name  string
	Value interface{}
	Type  string
}

type ServerLogModel

type ServerLogModel struct {
	ServerName   string `json:"serverName"`
	Env          string `json:"env"`
	TimeStamp    int64  `json:"timeStamp"`
	ThreadNo     string `json:"threadNo"`
	ServerIp     string `json:"serverIp"`
	ClientIp     string `json:"clientIp"`
	Token        string `json:"token"`
	CustomerId   int32  `json:"customerId"`
	ClientSource string `json:"clientSource"`
	Url          string `json:"url"`
	Method       string `json:"method"`
	Request      string `json:"request"`
	Response     string `json:"response"`
	DealTimes    int64  `json:"dealTimes"`
}

func QueryLogs

func QueryLogs(indexName string, params []QueryParams, sortsDesc map[string]bool, from, size int) (total int64, data []ServerLogModel)

Jump to

Keyboard shortcuts

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