Documentation
¶
Index ¶
- func BulkDelete[D DocIdGetter](index string, docs []D) error
- func BulkIndex[D DocIdGetter](index string, docs []D) error
- func Client() *elasticsearch.TypedClient
- func GetDocById[T any](index string, id string) (*T, error)
- func InitEs(addresses []string, username string, password string, debug bool)
- func QueryTerm[T any](index string, from int, size int, termMap map[string]any) (records []T, total int, err error)
- func QueryTerms[T any](index string, filed string, values []any) ([]T, error)
- func QueryTermsId[T any](index string, values []any) ([]T, error)
- type DocIdGetter
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func BulkDelete ¶
func BulkDelete[D DocIdGetter](index string, docs []D) error
func BulkIndex ¶
func BulkIndex[D DocIdGetter](index string, docs []D) error
func Client ¶
func Client() *elasticsearch.TypedClient
Types ¶
type DocIdGetter ¶
type DocIdGetter interface {
GetDocId() string
}
Click to show internal directories.
Click to hide internal directories.