pagees

package
v1.0.1-rel-02 Latest Latest
Warning

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

Go to latest
Published: Nov 12, 2024 License: AFL-3.0 Imports: 24 Imported by: 0

README

func Test050_HttpQuery2EsResult(t *testing.T) {

	var pagereq = Default()
	pagereq.CmdType = esconst.ES_HTTPCLI_QUERY
	pagereq.IndexName = "dev_commerce_order_payment"
	pagereq.HttpcliBody = `"bool":{"must":[{"terms":{"txid":["pay_01H51WE4NC22RN2CXMA8K9NKG7"]}},{"range":{"updated_at":{"from":0,"include_lower":true,"include_upper":true,"to":1724133330}}}]}`
	pagereq.SearchType = "dfs_query_then_fetch"
	pagereq.Source = "sn_id,amount"
	pagereq.OrderByAscScore("txid")
	pagereq.OrderByDescScore("updated_at")
	var result = pagereq.HttpQuery2EsResult()
	logrus.Info(result)

}


Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func InjectPageEsRequest

func InjectPageEsRequest(s *PageEsRequest)

func InjectPageEsRequestAggStats

func InjectPageEsRequestAggStats(s *PageEsRequestAggStats)

func InjectPageEsResult

func InjectPageEsResult(s *PageEsResult)

func InjectPageEsWebClient

func InjectPageEsWebClient(s *PageEsWebClient)

func InjectPageEsWebClients

func InjectPageEsWebClients(s *PageEsWebClients)

func LoadPageEsRequest

func LoadPageEsRequest() baseiface.ISingleton

func LoadPageEsRequestAggStats

func LoadPageEsRequestAggStats() baseiface.ISingleton

func LoadPageEsResult

func LoadPageEsResult() baseiface.ISingleton

func LoadPageEsWebClient

func LoadPageEsWebClient() baseiface.ISingleton

func LoadPageEsWebClients

func LoadPageEsWebClients() baseiface.ISingleton

Types

type AggResult

type AggResult any

type KeyCount

type KeyCount struct {
	Key       any         `json:"key"`
	KeyNumber json.Number `json:"key_number"`
	DocCount  int64       `json:"doc_count"`
	KeyCounts []*KeyCount `json:"key_counts,omitempty"`
}

func NewKeyCount

func NewKeyCount() *KeyCount

type PageEsQuery

type PageEsQuery struct {
	// contains filtered or unexported fields
}

func NewPageEsQuery

func NewPageEsQuery(pageEsRequest *PageEsRequest) *PageEsQuery

func (*PageEsQuery) AddGroup

func (this *PageEsQuery) AddGroup(field *dto2.QueryField, query elastic.Query) elastic.Query

func (*PageEsQuery) BuildBoolQuery

func (this *PageEsQuery) BuildBoolQuery(esreq *PageEsRequest) *elastic.BoolQuery

func (*PageEsQuery) BuildQuery

func (this *PageEsQuery) BuildQuery() *elastic.BoolQuery

func (*PageEsQuery) ExistQuery

func (this *PageEsQuery) ExistQuery() []elastic.Query

func (*PageEsQuery) FuzzyQuery

func (this *PageEsQuery) FuzzyQuery() []elastic.Query

func (*PageEsQuery) IdQuery

func (this *PageEsQuery) IdQuery() []elastic.Query

func (*PageEsQuery) IdsQuery

func (this *PageEsQuery) IdsQuery() []elastic.Query

func (*PageEsQuery) MatchAllQuery

func (this *PageEsQuery) MatchAllQuery() []elastic.Query

func (*PageEsQuery) MatchPhrase

func (this *PageEsQuery) MatchPhrase() []elastic.Query

func (*PageEsQuery) MatchQuery

func (this *PageEsQuery) MatchQuery() []elastic.Query

text

func (*PageEsQuery) MoreLikeQuery

func (this *PageEsQuery) MoreLikeQuery() []elastic.Query

func (*PageEsQuery) PrefixQuery

func (this *PageEsQuery) PrefixQuery() []elastic.Query

func (*PageEsQuery) RangeQuery

func (this *PageEsQuery) RangeQuery() []elastic.Query

func (*PageEsQuery) RegexpQuery

func (this *PageEsQuery) RegexpQuery() []elastic.Query

func (*PageEsQuery) TermQuery

func (this *PageEsQuery) TermQuery() []elastic.Query

match term keyword

func (*PageEsQuery) TermsQuery

func (this *PageEsQuery) TermsQuery() []elastic.Query

func (*PageEsQuery) WildcardQuery

func (this *PageEsQuery) WildcardQuery() []elastic.Query

type PageEsRequest

type PageEsRequest struct {
	basedto.BaseEntity
	*page.PageRequest
	*esdto.EsRequest

	// 返回原生响应
	AttachResp bool `json:"-"`
	// DFS_QUERY_THEN_FETCH,QUERY_THEN_FETCH,DFS_QUERY_AND_FETCH,QUERY_AND_FETCH
	SearchType         string `json:"search_type"`
	MaxResponseSize    int    `json:"max_response_size"`
	TrackTotalHits     bool   `json:"track_total_hits"`
	RestTotalHitsAsInt bool   `json:"rest_total_hits_as_int""`

	EsAggDtos []*esdto.EsAggDto `json:"es_agg_dtos"`
	QueryBoth bool              `json:"query_both"` // query and agg

	PageEsRequests  []*PageEsRequest `json:"page_es_requests"`
	PageEsBoolTypes []int            `json:"page_es_bool_types"`
	// contains filtered or unexported fields
}

func Default

func Default() *PageEsRequest

func FindBeanPageEsRequest

func FindBeanPageEsRequest() *PageEsRequest

FindBeanPageEsRequest

func NewEsRequest

func NewEsRequest(pageSize, current int) *PageEsRequest

func NewPageEsRequest

func NewPageEsRequest(indexName string) *PageEsRequest

func (*PageEsRequest) AddGroup

func (self *PageEsRequest) AddGroup(field *dto2.QueryField, query elastic.Query) elastic.Query

func (*PageEsRequest) AddGroups

func (self *PageEsRequest) AddGroups(field *dto2.QueryField, query elastic.Query) elastic.Query

func (*PageEsRequest) Boost

func (self *PageEsRequest) Boost(value float64) *PageEsRequest

func (*PageEsRequest) BuildBoolQuery

func (self *PageEsRequest) BuildBoolQuery() *elastic.BoolQuery

func (*PageEsRequest) BuildSource

func (self *PageEsRequest) BuildSource(service *elastic.SearchService)

func (*PageEsRequest) Clear

func (self *PageEsRequest) Clear()

func (*PageEsRequest) ClearAggStats

func (self *PageEsRequest) ClearAggStats()

func (*PageEsRequest) Default

func (self *PageEsRequest) Default()

func (*PageEsRequest) DoAggStats

func (self *PageEsRequest) DoAggStats(searchService *elastic.SearchService) (*elastic.SearchResult, AggResult, error)

func (*PageEsRequest) EsAggAvg

func (self *PageEsRequest) EsAggAvg(aggField string, statField string, size ...int) *PageEsRequest

func (*PageEsRequest) EsAggCount

func (self *PageEsRequest) EsAggCount(aggField string, size ...int) *PageEsRequest

func (*PageEsRequest) EsAggMax

func (self *PageEsRequest) EsAggMax(aggField string, statField string, size ...int) *PageEsRequest

func (*PageEsRequest) EsAggMin

func (self *PageEsRequest) EsAggMin(aggField string, statField string, size ...int) *PageEsRequest

func (*PageEsRequest) EsAggStats

func (self *PageEsRequest) EsAggStats(aggField string, statField string, size ...int) *PageEsRequest

func (*PageEsRequest) EsAggSum

func (self *PageEsRequest) EsAggSum(aggField string, statField string, size ...int) *PageEsRequest

func (*PageEsRequest) EsAvg

func (self *PageEsRequest) EsAvg(statField string, size ...int) *PageEsRequest

func (*PageEsRequest) EsBoolQuery

func (self *PageEsRequest) EsBoolQuery() (*elastic.SearchResult, error)

func (*PageEsRequest) EsBoolQueryAgg

func (self *PageEsRequest) EsBoolQueryAgg() (*elastic.SearchResult, AggResult, error)

func (*PageEsRequest) EsCount

func (self *PageEsRequest) EsCount(size ...int) *PageEsRequest

func (*PageEsRequest) EsExistQuery

func (self *PageEsRequest) EsExistQuery(field string) *PageEsRequest

func (*PageEsRequest) EsFilter

func (self *PageEsRequest) EsFilter() *PageEsRequest

func (*PageEsRequest) EsFindId

func (self *PageEsRequest) EsFindId(id string) (*elastic.GetResult, error)

func (*PageEsRequest) EsFindIds

func (self *PageEsRequest) EsFindIds(ids ...string) (*elastic.SearchResult, error)

func (*PageEsRequest) EsFindTerm

func (self *PageEsRequest) EsFindTerm(field string, value interface{}) (*elastic.SearchResult, error)

func (*PageEsRequest) EsFindTerms

func (self *PageEsRequest) EsFindTerms(key string, values ...interface{}) (*elastic.SearchResult, error)

func (*PageEsRequest) EsFuzzy

func (self *PageEsRequest) EsFuzzy(field string, opValue interface{}) *PageEsRequest

func (*PageEsRequest) EsGetMapping

func (self *PageEsRequest) EsGetMapping(indexName string) (map[string]interface{}, error)

func (*PageEsRequest) EsId

func (self *PageEsRequest) EsId(opValue interface{}) *PageEsRequest

func (*PageEsRequest) EsIds

func (self *PageEsRequest) EsIds(opValues []interface{}) *PageEsRequest

func (*PageEsRequest) EsMatch

func (self *PageEsRequest) EsMatch(field string, opValue interface{}) *PageEsRequest

func (*PageEsRequest) EsMatchAll

func (self *PageEsRequest) EsMatchAll() *PageEsRequest

func (*PageEsRequest) EsMatchPhrase

func (self *PageEsRequest) EsMatchPhrase(field string, opValue interface{}) *PageEsRequest

func (*PageEsRequest) EsMax

func (self *PageEsRequest) EsMax(statField string, size ...int) *PageEsRequest

func (*PageEsRequest) EsMin

func (self *PageEsRequest) EsMin(statField string, size ...int) *PageEsRequest

func (*PageEsRequest) EsMoreLike

func (self *PageEsRequest) EsMoreLike(field string, opValue ...interface{}) *PageEsRequest

func (*PageEsRequest) EsMust

func (self *PageEsRequest) EsMust() *PageEsRequest

func (*PageEsRequest) EsMustNot

func (self *PageEsRequest) EsMustNot() *PageEsRequest

func (*PageEsRequest) EsPrefix

func (self *PageEsRequest) EsPrefix(field string, opValue ...interface{}) *PageEsRequest

func (*PageEsRequest) EsQuery

func (self *PageEsRequest) EsQuery() (*elastic.SearchResult, error)

func (*PageEsRequest) EsQueryCount

func (self *PageEsRequest) EsQueryCount() (int64, error)

排序字段是keyword

func (*PageEsRequest) EsQueryResult

func (self *PageEsRequest) EsQueryResult() (*PageEsResult, error)

func (*PageEsRequest) EsQueryResultBoth

func (self *PageEsRequest) EsQueryResultBoth() (*PageEsResult, error)

func (*PageEsRequest) EsRange

func (self *PageEsRequest) EsRange(field string, opValue ...interface{}) *PageEsRequest

func (*PageEsRequest) EsRangeGe

func (self *PageEsRequest) EsRangeGe(field string, opValue interface{}) *PageEsRequest

func (*PageEsRequest) EsRangeGt

func (self *PageEsRequest) EsRangeGt(field string, opValue interface{}) *PageEsRequest

func (*PageEsRequest) EsRangeLe

func (self *PageEsRequest) EsRangeLe(field string, opValue interface{}) *PageEsRequest

func (*PageEsRequest) EsRangeLt

func (self *PageEsRequest) EsRangeLt(field string, opValue interface{}) *PageEsRequest

func (*PageEsRequest) EsRegexp

func (self *PageEsRequest) EsRegexp(field string, opValue interface{}) *PageEsRequest

func (*PageEsRequest) EsShould

func (self *PageEsRequest) EsShould() *PageEsRequest

func (*PageEsRequest) EsStats

func (self *PageEsRequest) EsStats(statField string, size ...int) *PageEsRequest

func (*PageEsRequest) EsSum

func (self *PageEsRequest) EsSum(statField string, size ...int) *PageEsRequest

func (*PageEsRequest) EsTerm

func (self *PageEsRequest) EsTerm(field string, opValue interface{}) *PageEsRequest

func (*PageEsRequest) EsTerms

func (self *PageEsRequest) EsTerms(field string, opValues ...interface{}) *PageEsRequest

func (*PageEsRequest) EsWildcard

func (self *PageEsRequest) EsWildcard(field string, opValues ...interface{}) *PageEsRequest

func (*PageEsRequest) ExistId

func (self *PageEsRequest) ExistId() (bool, error)

func (*PageEsRequest) FromSize

func (self *PageEsRequest) FromSize(from, size int) *PageEsRequest

FromSize(from,size).

func (*PageEsRequest) HttpQuery

func (self *PageEsRequest) HttpQuery(query elastic.Query) *PageEsResult

func (*PageEsRequest) HttpQuery2EsResult

func (self *PageEsRequest) HttpQuery2EsResult() *PageEsResult

func (*PageEsRequest) HttpQuery2EsResultBase

func (self *PageEsRequest) HttpQuery2EsResultBase(body string) *PageEsResult

func (*PageEsRequest) HttpQuery2EsResultSource

func (self *PageEsRequest) HttpQuery2EsResultSource() *PageEsResult

func (*PageEsRequest) IfAggStats

func (self *PageEsRequest) IfAggStats() bool

func (*PageEsRequest) IfFilter

func (self *PageEsRequest) IfFilter() bool

func (*PageEsRequest) IfIndexMulti

func (self *PageEsRequest) IfIndexMulti() bool

func (*PageEsRequest) IfMust

func (self *PageEsRequest) IfMust() bool

func (*PageEsRequest) IfMustNot

func (self *PageEsRequest) IfMustNot() bool

func (*PageEsRequest) IfShould

func (self *PageEsRequest) IfShould() bool

func (*PageEsRequest) Ini

func (self *PageEsRequest) Ini(clientDto *baseconfig.ElasticClientDto)

func (*PageEsRequest) IniHttpurlParams

func (self *PageEsRequest) IniHttpurlParams()

func (*PageEsRequest) InitPage

func (this *PageEsRequest) InitPage()

func (*PageEsRequest) Nest

func (self *PageEsRequest) Nest(subs ...*PageEsRequest) *PageEsRequest

func (*PageEsRequest) Open

func (self *PageEsRequest) Open()

func (*PageEsRequest) SetAttachResp

func (self *PageEsRequest) SetAttachResp(attachResp bool) *PageEsRequest

func (*PageEsRequest) SetCmdType

func (self *PageEsRequest) SetCmdType(CmdType esconst.CMDTYPE) *PageEsRequest

func (*PageEsRequest) SetHttpcliBody

func (self *PageEsRequest) SetHttpcliBody(HttpcliBody string) *PageEsRequest

func (*PageEsRequest) SetHttpurlParams

func (self *PageEsRequest) SetHttpurlParams(HttpurlParams map[string]any) *PageEsRequest

const V_BodyQuery = `{ "query":{ "match_all":{ } } }` func (this *PageEsRequest) PostWeb2EsResult(webMsg *webmsg.WebMsg) *PageEsResult {

func (*PageEsRequest) SetIndexName

func (self *PageEsRequest) SetIndexName(IndexName string) *PageEsRequest

func (*PageEsRequest) SetPageCurrent

func (self *PageEsRequest) SetPageCurrent(PageCurrent int) *PageEsRequest

func (*PageEsRequest) SetPageSize

func (self *PageEsRequest) SetPageSize(PageSize int) *PageEsRequest

func (*PageEsRequest) SetQueryBoth

func (self *PageEsRequest) SetQueryBoth(queryBoth bool) *PageEsRequest

func (*PageEsRequest) SetSource

func (self *PageEsRequest) SetSource(Source string) *PageEsRequest

func (*PageEsRequest) SortField

func (self *PageEsRequest) SortField(field string, asc bool) elastic.Sorter

Sort("content_id", true).

func (*PageEsRequest) ToHttpQueryBody

func (self *PageEsRequest) ToHttpQueryBody() *esdto.HttpQueryBody

func (*PageEsRequest) ToHttpQueryParams

func (self *PageEsRequest) ToHttpQueryParams() *esdto.HttpQueryParams

func (*PageEsRequest) ValueOfPageRequest

func (self *PageEsRequest) ValueOfPageRequest(that *PageEsRequest) *PageEsRequest

type PageEsRequestAggStats

type PageEsRequestAggStats struct {
	basedto.BaseEntity
	*PageEsRequest
}

使用连接池

func DefaultAggStats

func DefaultAggStats() *PageEsRequestAggStats

func FindBeanPageEsRequestAggStats

func FindBeanPageEsRequestAggStats() *PageEsRequestAggStats

FindBeanPageEsRequestAggStats

func NewAggStats

func NewAggStats(req *PageEsRequest) *PageEsRequestAggStats

func (*PageEsRequestAggStats) Agg2Map

func (self *PageEsRequestAggStats) Agg2Map(aggs elastic.Aggregations, field string, usekey bool) (map[string]int64, error)

func (*PageEsRequestAggStats) Agg2MapResult

func (self *PageEsRequestAggStats) Agg2MapResult(aggs elastic.Aggregations, field string, usekey bool) (map[string]*esdto.EsAggResult, error)

func (*PageEsRequestAggStats) Agg2MapResult2Map

func (self *PageEsRequestAggStats) Agg2MapResult2Map(aggs elastic.Aggregations, field string, usekey bool) (map[string]any, error)

func (*PageEsRequestAggStats) Agg2Result

func (this *PageEsRequestAggStats) Agg2Result(aggs elastic.Aggregations) (*esdto.EsAggResult, error)

"search_result": { "hits": { "total": { "value": 53, "relation": "eq" } }, "aggregations": { "stats": { "count" : 53, "min" : 10.0, "max" : 40.0, "avg" : 29.245283018867923, "sum" : 1550.0 }

func (*PageEsRequestAggStats) AggAvg

func (this *PageEsRequestAggStats) AggAvg(searchService *elastic.SearchService) (*elastic.SearchResult, error)

func (*PageEsRequestAggStats) AggCount

func (this *PageEsRequestAggStats) AggCount(searchService *elastic.SearchService) (*elastic.SearchResult, error)

func (*PageEsRequestAggStats) AggCountSub

func (this *PageEsRequestAggStats) AggCountSub(searchService *elastic.SearchService) (*elastic.SearchResult, error)

func (*PageEsRequestAggStats) AggMax

func (this *PageEsRequestAggStats) AggMax(searchService *elastic.SearchService) (*elastic.SearchResult, error)

func (*PageEsRequestAggStats) AggMin

func (this *PageEsRequestAggStats) AggMin(searchService *elastic.SearchService) (*elastic.SearchResult, error)

func (*PageEsRequestAggStats) AggStats

func (this *PageEsRequestAggStats) AggStats(searchService *elastic.SearchService) (*elastic.SearchResult, error)

func (*PageEsRequestAggStats) AggSum

func (this *PageEsRequestAggStats) AggSum(searchService *elastic.SearchService) (*elastic.SearchResult, error)

func (*PageEsRequestAggStats) EsStats

func (this *PageEsRequestAggStats) EsStats(searchService *elastic.SearchService) (*elastic.SearchResult, error)

func (*PageEsRequestAggStats) FindAggDto

func (this *PageEsRequestAggStats) FindAggDto() *esdto.EsAggDto

func (*PageEsRequestAggStats) Parse

func (this *PageEsRequestAggStats) Parse(searchResult *elastic.SearchResult) (AggResult, error)

func (*PageEsRequestAggStats) ParseAggCount

func (this *PageEsRequestAggStats) ParseAggCount(searchResult *elastic.SearchResult) (map[string]int64, error)

func (*PageEsRequestAggStats) ParseAggCountSub

func (this *PageEsRequestAggStats) ParseAggCountSub(searchResult *elastic.SearchResult) ([]*KeyCount, error)

func (*PageEsRequestAggStats) ParseAggStats

func (this *PageEsRequestAggStats) ParseAggStats(searchResult *elastic.SearchResult) (map[string]*esdto.EsAggResult, error)

func (*PageEsRequestAggStats) ParseAggStats2Map

func (this *PageEsRequestAggStats) ParseAggStats2Map(searchResult *elastic.SearchResult) (map[string]any, error)

func (*PageEsRequestAggStats) ParseStats

func (this *PageEsRequestAggStats) ParseStats(searchResult *elastic.SearchResult) (*esdto.EsAggResult, error)
func (this *PageEsRequestAggStats) Agg2Result(aggs elastic.Aggregations) (*esdto.EsAggResult, error) {
	var aggdto = this.FindAggDto()

	var result = esdto.NewEsAggResult()
	var esstats = esdto.NewEsStats()
	esstats.Value2Stats(aggs)
	result.Avg = esstats.Stats.Avg
	result.Sum = esstats.Stats.Sum
	result.Max = esstats.Stats.Max
	result.Min = esstats.Stats.Min
	result.Count = esstats.Stats.Count
	result.StatField = aggdto.StatField
	result.AggType = esdto.AggType_Stats
	return result, nil
}

func (*PageEsRequestAggStats) QueryAggCount

func (self *PageEsRequestAggStats) QueryAggCount(field string, size int, usekey bool) (map[string]int64, error)

func (*PageEsRequestAggStats) Stats

func (this *PageEsRequestAggStats) Stats(searchService *elastic.SearchService) (*elastic.SearchResult, error)

func (*PageEsRequestAggStats) StatsFields

func (this *PageEsRequestAggStats) StatsFields(searchService *elastic.SearchService) (*elastic.SearchResult, error)

func (*PageEsRequestAggStats) StatsOne

func (this *PageEsRequestAggStats) StatsOne(searchService *elastic.SearchService) (*elastic.SearchResult, error)

GET dev_biz_grouping_buy_line/_search/

{
  "query": {
    "match_all": {}
  },
  "size":1,
  "sort": [
    {
      "shop_id":   "desc"
    },
        {
      "updated_by":   "desc"
    }

  ],
   "aggs": {
    "stats": {
        "stats": {
            "field": "state"
        }
    }, "stats": {
        "stats": {
            "field": "price"
        }
    }

   }
}

func (*PageEsRequestAggStats) TermsAgg

func (self *PageEsRequestAggStats) TermsAgg(field string, size int, usekey bool) *elastic.TermsAggregation

type PageEsResult

type PageEsResult struct {
	basedto.BaseEntity
	*page.PageResult

	RequestId    string                `json:"request_id"`
	SearchResult *elastic.SearchResult `json:"search_result,omitempty"`
}

func DefaultResult

func DefaultResult() *PageEsResult

func FailedPageEsResult

func FailedPageEsResult(msg string) *PageEsResult

func FailedPageEsResultErr

func FailedPageEsResultErr(err error) *PageEsResult

func FindBeanPageEsResult

func FindBeanPageEsResult() *PageEsResult

FindBeanPageEsResult

func NewIchubPageEsResult

func NewIchubPageEsResult() *PageEsResult

func PageEsResultOfSearch

func PageEsResultOfSearch(SearchResult *elastic.SearchResult, attach bool) (pes *PageEsResult)

@Title 文件名称: pageesresponse.go @Description 描述: es响应消息

@Author 作者: leijianming@163.com 时间(2024-02-22 22:38:21) @Update 作者: leijianming@163.com 时间(2024-02-21 22:38:21)

func ResultExist

func ResultExist(exist bool) *PageEsResult

func ResultOk

func ResultOk(data any) *PageEsResult

func (*PageEsResult) As

func (pes *PageEsResult) As(out interface{}) *PageEsResult

func (*PageEsResult) DataAsArrays

func (pes *PageEsResult) DataAsArrays() []map[string]interface{}

func (*PageEsResult) FailMsg

func (pes *PageEsResult) FailMsg(Msg string) *PageEsResult

func (*PageEsResult) From

func (pes *PageEsResult) From(result *basedto.IchubResult) *PageEsResult

func (*PageEsResult) FromHitsHits

func (pes *PageEsResult) FromHitsHits(hits []*elastic.SearchHit) *PageEsResult

func (*PageEsResult) FromJson

func (pes *PageEsResult) FromJson(body []byte) interface{}

func (*PageEsResult) Hits2Map

func (pes *PageEsResult) Hits2Map(indexmulti bool, hits []*elastic.SearchHit) []map[string]any

func (*PageEsResult) Hits2Sources

func (pes *PageEsResult) Hits2Sources(hits []*elastic.SearchHit) *[]json.RawMessage

func (*PageEsResult) Init

func (pes *PageEsResult) Init()

func (*PageEsResult) InitPage

func (pes *PageEsResult) InitPage()

func (*PageEsResult) PageEsResultData2Map

func (pes *PageEsResult) PageEsResultData2Map()

func (*PageEsResult) PageEsResultOf

func (pes *PageEsResult) PageEsResultOf(request *PageEsRequest, searchRes *elastic.SearchResult)

func (*PageEsResult) PageEsResultOfSearch

func (pes *PageEsResult) PageEsResultOfSearch(searchRes *elastic.SearchResult, attach bool) *PageEsResult

func (*PageEsResult) ParseHighlight

func (pes *PageEsResult) ParseHighlight(searchRes *elastic.SearchResult) []elastic.SearchHitHighlight

func (*PageEsResult) Shutdown

func (pes *PageEsResult) Shutdown()

func (*PageEsResult) ValueOfRequest

func (pes *PageEsResult) ValueOfRequest(req *PageEsRequest)

type PageEsWebClient

type PageEsWebClient struct {
	basedto.BaseEntity
	*webclient.WebClient
	EsRandSeq int    `json:"-"`
	Attach    bool   `json:"-"`
	Host      string `json:"-"`
}

func FindBeanPageEsWebClient

func FindBeanPageEsWebClient() *PageEsWebClient

FindBeanPageEsWebClient

func NewPageEsWebClient

func NewPageEsWebClient() *PageEsWebClient

func (*PageEsWebClient) BuildEsHttpHost

func (self *PageEsWebClient) BuildEsHttpHost() string

dest esserver

func (*PageEsWebClient) BuildQueryUrl

func (self *PageEsWebClient) BuildQueryUrl(esreq *PageEsRequest) string

func (*PageEsWebClient) Check

func (self *PageEsWebClient) Check(esreq *PageEsRequest) error

type PageEsWebClients

type PageEsWebClients struct {
	basedto.BaseEntitySingle
	WebClients []*PageEsWebClient
}

func FindBeanPageEsWebClients

func FindBeanPageEsWebClients() *PageEsWebClients

FindBeanPageEsWebClients

func NewPageEsWebClients

func NewPageEsWebClients() *PageEsWebClients

func (*PageEsWebClients) FindWebClient

func (self *PageEsWebClients) FindWebClient() *PageEsWebClient

func (*PageEsWebClients) Init

func (self *PageEsWebClients) Init()

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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