自定义博客皮肤VIP专享

*博客头图:

格式为PNG、JPG,宽度*高度大于1920*100像素,不超过2MB,主视觉建议放在右侧,请参照线上博客头图

请上传大于1920*100像素的图片!

博客底图:

图片格式为PNG、JPG,不超过1MB,可上下左右平铺至整个背景

栏目图:

图片格式为PNG、JPG,图片宽度*高度为300*38像素,不超过0.5MB

主标题颜色:

RGB颜色,例如:#AFAFAF

Hover:

RGB颜色,例如:#AFAFAF

副标题颜色:

RGB颜色,例如:#AFAFAF

自定义博客皮肤

-+
  • 博客(9)
  • 收藏
  • 关注

转载 如何正确实现Page接口分页,用PageImpl 自定义分页

/** * Constructor of {@code PageImpl}. * * @param content the content of this page, must not be {@literal null}. * @param pageable the paging information, must not be {@literal null}. * @param t...

2018-12-27 22:59:00 3296

转载 springboot2.0 集成elasticsearch,实现检索、分页、排序

springboot整合es的方式:transport方式(7.0弃用,8.0移除)spring-data(完全当做数据库来用,无法全部支持es,内部也是基于transport,包装后使用非常简单,和JPA基本类似)rest(low-level和high-level,low-level非常完善,支持所有版本,需要自己组装request和解析response,high-le...

2018-12-26 15:48:00 1702

转载 Elasticsearch query和filter的区别

1、关于Query context和filter context查询语句的表现行为取决于使用了查询上下文方式还是过滤上下文方式。Query context:查询上下文,回答了“文档是如何被查询语句匹配的”,此外,也决定了文档是否被匹配上,查询语句也通过计算_score的值来说明文档的匹配度。query context查询方式是通过传递query参数来实现。Filter conte...

2018-12-25 16:48:00 155

转载 Elasticsearch cat Apis

1、_cat列入所有有效命令GET /_cat返回:有个猫...所以不难想象为啥是cat api=^.^=/_cat/allocation/_cat/shards/_cat/shards/{index}/_cat/master/_cat/nodes/_cat/tasks/_cat/indices/_cat/indices/{index}...

2018-12-25 13:36:00 168

转载 Elasticsearch 更新索引settings

1、更新索引设置:将副本减至0,修改索引分析器为ik_max_word和检索分词器为ik_smart2、需要先将索引关闭,然后再PUT setingsPOST user/_closePUT user/_settings{ "number_of_replicas": 0, "index":{ "analysis.analyzer.default...

2018-12-24 16:20:00 1042

转载 Elasticsearch 中文分词器IK

1、安装说明https://github.com/medcl/elasticsearch-analysis-ik2、release版本https://github.com/medcl/elasticsearch-analysis-ik/releases3、安装插件bin/elasticsearch-plugin install https://github.com...

2018-12-12 13:27:00 137

转载 Elasticsearch 检索

1、 检索所有文档GET bus/product/_search2、 term检索term是代表完全匹配,也就是精确查询,搜索前不会再对搜索词进行分词,所以我们的搜索词必须是文档分词集合中的一个,如果没有安装分词插件,汉字分词按每个汉字来分。查询不到内容:GET bus/product/_search{ "query": { "term...

2018-12-10 23:15:00 89

转载 Elasticsearch 基本操作

1、创建索引1.1、使用缺省配置创建索引(5个分片,1个副本)PUT test索引名称test必须小写1.2、指定分片和副本:PUT mytest{ "settings": { "number_of_shards": 3, "number_of_replicas": 1 } }2、查看索引2.1、查看...

2018-12-03 22:39:00 174

转载 Elasticsearch 集群

一、两台机器centos:192.168.31.10win7:192.168.1.101二、配置# ---------------------------------- Cluster -----------------------------------## Use a descriptive name for your cluster:##clus...

2018-12-01 12:50:00 58

空空如也

空空如也

TA创建的收藏夹 TA关注的收藏夹

TA关注的人

提示
确定要删除当前文章?
取消 删除