随笔分类 -  ElasticSearch

摘要:1、scroll深度搜索,查询符合条件的所有数据。如果不是scroll深度搜索默认之后返回20条数据,如果指定分页就返回分页的条数。 package com.example.demo; import org.elasticsearch.action.search.SearchResponse; im 阅读全文
posted @ 2020-04-13 22:34 N神3 阅读(2576) 评论(0) 推荐(0) 编辑
摘要:1、连接elasticseach public class ElasticSearchComponent { TransportClient client = null; public ESClientSettings() { Settings settings = ImmutableSetting 阅读全文
posted @ 2019-12-13 16:21 N神3 阅读(1515) 评论(0) 推荐(0) 编辑
摘要:1、es search sroll 可以遍历索引下所有数据 2、es search sroll 可以遍历索引下所有数据。与上面差别是利用SearchSourceBuilder构造查询条件。 阅读全文
posted @ 2019-05-23 23:37 N神3 阅读(737) 评论(0) 推荐(0) 编辑
摘要:elasticsearch官方API https://www.elastic.co/guide/en/elasticsearch/client/java-api/current/index.html 一、restful api查询 1.1、查询订单 POST order/_search?q=P201 阅读全文
posted @ 2019-03-23 09:18 N神3 阅读(2345) 评论(0) 推荐(0) 编辑
摘要:1、安装JDK:centos删除openJDK,安装JDK,vim /etc/profile配置JAVA_HOME 2、官网下载elasticsearch:https://www.elastic.co/downloads/elasticsearch 3、解压并启动:tar -zxvf /home/e 阅读全文
posted @ 2017-11-02 23:51 N神3 阅读(230) 评论(0) 推荐(0) 编辑

点击右上角即可分享
微信分享提示

喜欢请打赏

扫描二维码打赏

了解更多