Elasticsearch RestHighLevelClient 完整的各种查询

​​​​​​Elasticsearch Java High Level Rest Client API 主要分为:
全文查询 api,词项查询 api,特殊查询 api(按照聚合查询 api 和使用生成的建议查询 api 也算少数的特殊查询 api),复合查询 api。

https://blog.csdn.net/qq_42647903/article/details/120178755

全文查询 API 列表:

Search Query 名称 对应的QueryBuilder 的实现类 对应的 QueryBuilders 工厂方法(用以生成对应的 QueryBuilder)
Match MatchQueryBuilder QueryBuilders.matchQuery()
Match Phrase MatchPhraseQueryBuilder QueryBuilders.matchPhraseQuery()
Match Phrase Prefix MatchPhrasePrefixQueryBuilder QueryBuilders.matchPhrasePrefixQuery()
Multi Match MultiMatchQueryBuilder QueryBuilders.multiMatchQuery()
Common Terms CommonTermsQueryBuilder QueryBuilders.commonTermsQuery()
Query String QueryStringQueryBuilder QueryBuilders.queryStringQuery()
Simple Query String SimpleQueryStringBuilder QueryBuilders.simpleQueryStringQuery()

词项查询 API 列表:

Search Query 名称 对应的QueryBuilder 的实现类 对应的 QueryBuilders 工厂方法(用以生成对应的 QueryBuilder)
Term TermQueryBuilder QueryBuilders.termQuery()
Terms TermsQueryBuilder QueryBuilders.termsQuery()
Range RangeQueryBuilder QueryBuilders.rangeQuery()
Exists ExistsQueryBuilder QueryBuilders.existsQuery()
Prefix PrefixQueryBuilder QueryBuilders.prefixQuery()
Wildcard WildcardQueryBuilder QueryBuilders.wildcardQuery()
Regexp RegexpQueryBuilder QueryBuilders.regexpQuery()
Fuzzy FuzzyQueryBuilder QueryBuilders.fuzzyQuery()
Type TypeQueryBuilder QueryBuilders.typeQuery()
Ids IdsQueryBuilder QueryBuilders.idsQuery()

特殊查询 API 列表:

Search Query 名称 对应的 Builder 的实现类 对应的 Builders 工厂方法(用以生成对应的 Builder)
Aggregation TermsAggregationBuilder AggregationBuilders.terms()
Suggestion SuggestionBuilder SuggestBuilders.termSuggestion()

复合查询 API 列表:

Search Query 名称 对应的QueryBuilder 的实现类 对应的 QueryBuilders 工厂方法(用以生成对应的 QueryBuilder)
Constant Score ConstantScoreQueryBuilder QueryBuilders.constantScoreQuery()
Bool BoolQueryBuilder QueryBuilders.boolQuery()
Dis Max DisMaxQueryBuilder QueryBuilders.disMaxQuery()
Function Score FunctionScoreQueryBuilder QueryBuilders.functionScoreQuery()
Boosting BoostingQueryBuilder QueryBuilders.boostingQuery()

你可能感兴趣的:(elasticsearch,大数据,搜索引擎)